How do you handle extended or follow-up requirements in an LLD interview?
Fast recall
Quick revision
Core answer
Assessing whether you designed with the Open-Closed Principle in mind from the start and can extend functionality without breaking existing code.
Freshers immediately modify existing classes by adding if-else branches or flags like isElectric, which creates fragile code that violates the Open-Closed Principle.
Point to a specific abstraction you built earlier that now enables clean extension: 'I used ParkingSpot as an abstract class so adding ElectricSpot just means one new subclass with a chargingRate field'.
Interview-ready guide
Interview answer
When the interviewer adds a requirement mid-stream — say, now support electric-vehicle charging spots — I see it as a test of whether my design was open for extension, not as an attack. So my first move is to restate the requirement to make sure I understood it. Then I check whether my existing abstractions can absorb it. Ideally I can add a new subclass like ElectricChargingSpot, or a capability interface like Chargeable, and leave all the existing classes untouched. That's the Open/Closed Principle in action, and I'd narrate it: I'm adding a new class rather than editing working code, so nothing that already works can break.
The more interesting case is when my original design can't absorb the change cleanly. The wrong response is to hack it into existing classes or pretend the design already handles it — interviewers see straight through that. The right response is to be honest: I'd say something like, my current design assumed all spots are passive, so to support charging I'd introduce a Chargeable interface here and refactor these two classes. Naming the limitation and describing the refactor demonstrates more maturity than forcing an ugly workaround.
And whatever I do, I narrate it and I call out any trade-off the new requirement introduces — extra state to manage, new concurrency concerns, more complexity. Showing that I can evolve a design gracefully, and that I know when evolution requires a small refactor, is exactly what the follow-up is probing for.
How do you handle extended or follow-up requirements in an LLD interview
Direct Answer
When the interviewer adds a new requirement like 'support electric vehicle charging spots', extend your design using abstraction rather than modifying existing code. Introduce a new subclass like ElectricChargingSpot or add a capability interface. If your initial design doesn't accommodate this cleanly, acknowledge the limitation honestly and explain what refactoring you'd do to make it extensible.
Common Mistakes & Pitfalls
- Hacking it into existing classes — editing working code instead of extending it.
- Pretending the design handles it when it doesn't — interviewers see through this.
- Silent rewriting — narrate what you're changing and why.
- Ignoring trade-offs the new requirement introduces (e.g. extra state, sync needs).
Looking for a structured roadmap?
Every module on this page is also part of the full Java backend interview track.