~/problems
Problems
Basics first, then the classics, then company-style assessments. Every problem has tests you run right here; multi-level ones unlock as you go. See the roadmap.
Advanced & competitive
Search tricks
Ternary search, meet in the middle.
10 problems
Advanced & competitive
Search tricks Ternary search, meet in the middle.
Ternary search
- Basics: peak of a unimodal function on reals basics easy
- When is the drone closest to the beacons? py · c++ · java easy
- Peak of a mountain array easy
- Find Peak Element medium
- Minimize a black-box convex function Uber medium
- When to leave the elevator Uber py · c++ · java medium
Meet in the middle
- Basics: subset sums of two halves basics easy
- Trail mix with two exact targets py · c++ · java easy
- Subset sum closest to a goal py · c++ · java medium
- Count subsets with a target sum py · c++ · java medium