Workspace

Stacks

3 day streakD
All algorithms

Stack algorithms.

Track the top, preserve the invariant, then put it into code.

20 lessons · Python & C++

Stack foundations

02Medium

Min Stack

Store the minimum alongside each value for constant-time queries.

Expressions & parsing

Monotonic stacks

Areas & contributions

Simulation & greedy

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.

New tutorials are added one at a time. Your bookmarks and solved checkmarks stay in this browser.

Explore the roadmap