Skip to main content

Sliding Window Quiz

Editorial

11 questions across the three Sliding Window lessons: which window a task needs, what one step of each template does, what a step counts, and what a small bug returns. Pick an answer to see whether it's right and why. Nothing is saved, so you can take it again.

If one trips you up, its lesson is Introduction to Sliding Window, Variable-Size Sliding Window: Longest and Shortest or Counting Subarrays with a Sliding Window.

Quiz

1 / 11

Multiple choice

Find the largest sum of any 5 consecutive numbers. Which approach fits?