Workspace

Sliding Window

3 day streakD
All algorithms
INTERMEDIATE · 3 PRACTICE PROBLEMS

Sliding Window

Move your window. Keep what matters.

Learn the pattern Put it into practice
THE CORE IDEA

Sliding window

Maintain a useful slice of your input as its left and right boundaries move.

O(n)

A good place to practice

Start simple, then build up to the next challenge.

3 problems

A good place to start

Explore a pattern

A little guidance

Start with a pattern, read through a problem, and mark it solved when the idea clicks. Save anything you want to revisit.

This preview uses sample content. Your bookmarks and solved checkmarks stay in this browser.

Explore the roadmap