~/lld
lld(7)
Low-level design questions the way the interview runs them: a one-line prompt, questions you have to ask, a class diagram, design patterns, a sequence diagram and working code, graded step by step in the design studio. 6 questions, 47 scenario tests.
QUESTIONS
9001 Logger
Application code calls logger.info("..."). Your library decides what to keep, formats it and writes it somewhere. About 30 minutes.
easy · 7 scenarios · strategy, chain of responsibility, open/closed
9002 Parking Lot
A multi-level garage. Drivers take a ticket at the entrance and pay at the exit. You have about 45 minutes.
medium · 8 scenarios · inheritance, polymorphism, strategy, encapsulation
9003 Vending Machine
A snack machine that takes coins, sells from slots and gives change. About 35 minutes.
medium · 8 scenarios · state, encapsulation, validation
9004 Rate Limiter
An in-process limiter in front of an API. Each request asks: is this client allowed right now? About 30 minutes.
medium · 8 scenarios · strategy, factory, dependency injection
9005 Splitwise
Friends record who paid for what; the app tracks who owes whom and suggests how to settle up. About 40 minutes.
medium · 8 scenarios · strategy, validation, money handling, greedy
9006 Elevator System
The controller for a bank of elevators in one building. About 45 minutes.
hard · 8 scenarios · scheduling, state, simulation, strategy
HOW IT WORKS
- clarify ask the interviewer; the answers become the requirements
- entities pick the nouns that hold data and do work
- class diagram boxes and arrows in text: owns, has, uses, is-a, implements
- patterns name them; the coach checks the diagram has their shape
- sequence walk through the main use case, call by call
- implement code it in JavaScript against the scenario tests
- review a score out of 100, a hire signal, a reference design