How a low-level design round runs
After this: Know what to do in each part of a design round and how to answer the usual follow-ups.
On this page · 5 sections · 3 checks
You have now designed two systems from a paragraph: a parking lot and a library. In many software job interviews, this is a round of its own, often called a . This lesson shows one common way such a round runs, so you know what to do at each point. There is no code in it.
The shape of a round
Often the interviewer gives a short prompt, such as "Design a library system", and is there to answer your questions, in person or on a video call. Many rounds last 45 to 60 minutes. Here is one common way to use the time:
| Minutes | What you do | What the interviewer watches for |
|---|---|---|
| 0–5 | Ask questions, agree the requirements, say what is out of scope | You do not start drawing before you know the problem |
| 5–10 | List the classes (nouns) and their jobs (verbs) | Each class has one clear job |
| 10–20 | Draw the class diagram with the arrows | Sensible has-a and is-a choices; interfaces where kinds will grow |
| 20–40 | Write the core classes and the two or three main methods | Code that runs, readable names, rules kept inside the objects |
| 40–45+ | Extensions: a new kind, a new rule, two users at once | Changes land in one place; you name trade-offs out loud |
The library tutorial followed this order. Lesson 1 was the first two rows: the questions, the agreed paragraph, the nouns and verbs. The diagrams in lessons 2 and 3 were the third row. Lessons 2 to 4 wrote the core code. The final challenge is the last row.
Two habits help in every row. Talk while you work, so the interviewer hears your reasons as well as your answers. And when you make a choice, such as keeping the fine rule in its own class, say what you gave up and why it is worth it. That is what "name trade-offs out loud" means.
The follow-ups
The last part of the round is a set of changes. Three come up again and again:
- "Add a new kind." A student member, a teacher, an electric car. A good answer adds a class and changes as little else as possible. In the final challenge, the limit and the fine rule move into the member, so a new kind of member is one new class.
- "Change a rule." A weekend fine, a longer loan. A good answer points at the one class that holds the rule. Because the fine lives in
FinePolicy, a new fine rule is a new class built onFinePolicy, handed to the library in place of the old one. - "Two people at once." Two members ask for the last copy at the same moment, or two cars take the last spot. Both requests could see the copy as free before either marks it as taken. Often you are not asked to write the fix. Name it: finding the copy and marking it on loan must happen as one step that nothing else can interrupt, with a lock or a single database update.
A longer variant
Some companies run a longer version. The name you will most often hear for it, especially at companies in India, is a . It often lasts 90 minutes to two hours, and you write a complete program that runs. The steps are the same; there is more time for code, and less for talk. If a company names its rounds differently, ask the recruiter what each one expects.
Practise on your own
Here are four prompts with no solution given. For each one, set a timer for 45 minutes and follow the table: questions first, then nouns and verbs, then a diagram on paper, then code for the two or three main methods.
- An elevator. A building has several floors and one or more lifts. People press a button on a floor to call a lift, and press a floor button inside it. Questions to start with: how many lifts, which lift answers a call, and in which order does a lift visit the floors it has been asked for? Expect nouns such as building, elevator (the car), floor and request, and a rule for choosing a lift that may change, which is a Strategy again.
- A vending machine. Products in slots, coins in, change out, a product that runs out.
- Tic-tac-toe. Two players, a 3 by 3 board, turns, and a check for a winner.
- Movie tickets. Shows, seats, booking a seat, and two people wanting the same seat.
Check yourself
The interviewer says: “Design a library system.” What do you do in the first five minutes?
Which follow-up question is about two users at once?
The interviewer asks: “Teachers may borrow 10 books. How do you add a teacher?” Which answer keeps the change in one place?
- Run a design round in order: questions and scope, nouns and verbs, the class diagram, the core code, then the follow-ups.
- Answer a new kind or a new rule by pointing at the one class that changes or the one class you add.
- Answer two users at once by naming the fix: finding and taking the last item must be one step nothing can interrupt.
- Practise with prompts such as an elevator, a vending machine, tic-tac-toe and movie tickets, timed at 45 minutes.