Skip to content
Optimization line

Greedy problems

Problems where taking the best-looking choice at each step is always safe. The work is in seeing why that choice can never hurt; the code is often one pass.

The 8 problems

In the order the app teaches them. Each page has the problem, five hints and the explained solution.

On the roadmap

Greedy is a station on the optimization line. It builds on 2-D Dynamic Programming. Next comes Intervals.

The roadmap says why each line runs in its order.

Patterns

One pattern solves these problems. Naming them gives the problems’ methods away, so the list is folded.

Show it

Keep going