What is the step-by-step process for solving an LLD interview question?
Fast recall
Quick revision
Core answer
Whether you follow a structured problem-solving approach rather than randomly throwing classes together without reasoning.
Jumping straight into coding classes without clarifying ambiguous requirements or understanding the problem scope first.
Explicitly verbalize each step as you go—say 'Now I'm identifying entities' or 'Let me map the relationships'—shows disciplined thinking.
Interview-ready guide
Interview answer
I follow a five-step process, and having it memorised keeps me structured even when the problem is unfamiliar. Step one is clarify: I ask about scope, scale, and edge cases, because designing the wrong thing quickly is still designing the wrong thing. Step two is identify the core entities and actors, which I do with noun-verb analysis — nouns become candidate classes, verbs become methods. Step three is define responsibilities, applying the Single Responsibility Principle so each class has exactly one reason to change, rather than letting one God class absorb everything. Step four is map the relationships: I decide which links are is-a and use inheritance, which are has-a and use composition, and which are plain associations. Step five is apply design patterns where they genuinely fit, and then refine.
The single most important thing about the order is that patterns come last. A really common fresher mistake is to open with I'll use the Observer pattern before even understanding the domain, and that almost always leads to over-engineering — patterns bolted on for their own sake. Patterns should emerge from a problem you've actually identified, like pricing rules that change, which then justifies Strategy.
I'd also stress that the process isn't strictly linear. As I map relationships or apply a pattern, I often discover something that sends me back to adjust the entities or responsibilities, and that iteration is exactly what good design looks like, not a sign I got it wrong the first time.
What is the step-by-step process for solving an LLD interview question
Direct Answer
The standard LLD process has five steps: (1) Clarify requirements and constraints by asking questions, (2) Identify core entities and actors from the problem domain, (3) Define class responsibilities ensuring each class has one clear job (SRP), (4) Map relationships between classes using inheritance, composition, or association, (5) Apply design patterns where they naturally fit and refine the design iteratively.
Code Example
// Step 2: entities from "vehicles park in spots, get a ticket"
// Step 3: one responsibility each
class ParkingSpot { boolean free; boolean park(Vehicle v); } // occupancy only
class FeeCalculator { BigDecimal calculate(ParkingTicket t); } // pricing only
// Step 4: relationships
class ParkingLot {
private List<ParkingFloor> floors; // HAS-A (composition)
}
class Car extends Vehicle { } // IS-A (inheritance)
Each step produces a concrete artifact that feeds the next.
Common Mistakes & Pitfalls
- Skipping clarification — designing the wrong thing fast is still wrong.
- Patterns first — leading with patterns before understanding the domain = over-engineering.
- No responsibility check — entities pile up into God classes without SRP.
- Treating it as linear — you'll loop back and refine; that's expected, not a failure.
Looking for a structured roadmap?
Every module on this page is also part of the full Java backend interview track.