Skip to content

Design problems,
and the tell.

The problem asks you to build a class with operations that must each hit a time bound. 92 problems in the catalogue carry this tag, from first-week easy to interview hard.

Free to start. Running and submitting a solution never costs credits.

How the pattern actually works.

One mechanism, and the mistake that costs people the problem.

The tell. The problem asks you to build a class with operations that must each hit a time bound.

The mechanism. Pick the structures first and the methods write themselves. The usual answer is two structures that cover each other's weakness: a map for lookup plus a list or a linked list for order.

What goes wrong. Keeping two structures and forgetting to update both. Every write path has to touch each one.

The ones asked most often.

By how often the catalogue records them being set, not by our opinion.

  1. LRU CacheMediumasked at 101 companies
  2. Insert Delete GetRandom O(1)Mediumasked at 40 companies
  3. Logger Rate LimiterEasyasked at 7 companies
  4. Max StackHardasked at 4 companies
  5. Product of the Last K NumbersMediumasked at 2 companies
  6. Design a 3D Binary Matrix with Efficient Layer TrackingMediumasked at 1 companies
  7. Encrypt and Decrypt StringsHardasked at 1 companies
  8. Online Stock SpanMediumasked at 1 companies
  9. Find Consecutive Integers from a Data StreamMediumasked at 1 companies
  10. Operations on TreeMediumasked at 1 companies

Read it, watch it, then solve it.

The order that makes a pattern stick.

Everything in the app, in one place.

Practice, interviews and the tools, all free to start. Swipe to see the rest.

Free to start: 100 AI credits when you sign up and 100 every month. Start free in the app

About design problems.

Free to start, no card.

Start practising
How do I know a problem is a design problem?

The problem asks you to build a class with operations that must each hit a time bound.

How many design problems should I solve?

Enough to stop needing the hint, which is usually ten to fifteen across the levels, not the whole list. The catalogue tags 92, split roughly 11 easy, 60 medium and 21 hard in the sample we show, so work up rather than across.

What goes wrong most often in design problems?

Keeping two structures and forgetting to update both. Every write path has to touch each one.

Is practising by pattern better than a problem sheet?

A sheet tells you what to solve. A pattern tells you why those problems sit together, which is the part that carries over to the problem you have not seen. That is why the app files every problem under its pattern.