System Design in a Hurry
Interview cheat sheet
One-page interview crib: coding patterns, LLD 35-min spine, HLD delivery, STAR behavioral, and offer negotiation scripts — skim before each round.
Pooja Singh
8 min read
·
Jul 31, 2026
01 How to use this cheat sheet
01 Coding Pattern → invariant → code
02 LLD 35-min delivery spine
03 HLD Working system first
04 Behavioral STAR + story bank
05 Negotiate Band · delay · levers
Rules
Print or pin this page the morning of each round — skim the matching section only. Deep dives live elsewhere: checklist for coverage; this page is the speak-aloud crib . If you can’t say a line in ≤15 seconds, you don’t own it yet — open the linked post.
Coding LLD HLD Behavioral Negotiation
02 Coding cheat sheet
45-min clock
0–2 min: restate + constraints + examples (incl. empty / single).2–5 min: name the pattern + complexity before typing.5–20 min: code the happy path; narrate the invariant.20–25 min: edges + dry run one example aloud.Follow-up: expect a harder variant — reuse the invariant.
Pattern → when
Hash map — complement / freq / seen → arrays Two pointers / window — sorted pair or substring constraint → windows Binary search — sorted or search-on-answer; say the invariant → binary search Stack / mono stack — next greater, valid parens, calculator → stacks Heap — top-K, merge K, running median → stacks & heapsLinked list — reverse, cycle, merge, dummy head → lists Tree DFS/BFS — return contract; BST validate/insert → trees Graph — BFS levels, topo, Dijkstra when weights → graphs Union-Find — dynamic connectivity / cycle → DSU Intervals — sort by start/end; merge / meeting rooms → intervals Backtracking — choose → explore → undo; prune early → BT DP — state + transition + base; bottom-up or memo → DP Strings — palindrome / expand center / builder → strings Bits — XOR cancel, x&(x-1), masks if n≤20 → bits Prefix / trie / matrix → prefix & tries
Say before coding:
1) Pattern: _____
2) Invariant: _____
3) Time / space: _____ / _____
4) Edge cases I'll test: _____
03 LLD cheat sheet
35-min spine
~5 min Requirements + out of scope (write it).~3 min Entities & relationships (nouns that own state).10–15 min Class design / APIs (signatures before bodies).~10 min Core flow walkthrough (+ one concurrency note if relevant).~5 min Extensibility: what you’d add next without rewrite.
Requirements template:
In scope: …
Out of scope: UI / DB / network / …
Actors: …
Core ops: …
Invariants / rules: …
Failure modes: invalid input → …
Design cues
Separate domain rules from I/O (no HTTP in the core model). Prefer clear ownership: who mutates what? Patterns to name when earned: Strategy, Observer, Factory, Singleton (sparingly). Concurrency: identify shared mutable state → lock / queue / immutable snapshot. Say check-then-act risks aloud (reserve seat, inventory decrement).
Classic families
Parking / elevator / rate limiter → occupancy & quotas BookMyShow / locker / inventory → booking & stock Chess / Tic-Tac-Toe / Connect Four → rules engines Logger / filesystem → append & tree structure
Say this
“I’ll lock the design to these requirements, sketch classes with APIs first, walk one happy path, then call out the race on _____.”
04 HLD (system design) cheat sheet
45-min spine
~5 min Functional + non-functional + scale gut-check.~2 min Core entities.~5 min API (write the endpoints / events).~10–15 min High-level design — end-to-end working path.~10–15 min Deep dives pulled by NFRs (not random polish).Loop back: HLD must cover every FR; deep dives must address NFRs.
Clarify first:
- Users / actors?
- Read vs write ratio? Latency target?
- Consistency needs (strong / eventual)?
- Scale: DAU, QPS, payload size, retention?
- Single region or multi? Offline OK?
Then: API → boxes & arrows → bottlenecks → deep dives.
Capacity crib
Memory ~ns · SSD ~µs–ms · Net RTT same AZ ~sub-ms · cross-region ~tens–100ms+ Don’t invent fake bottlenecks — check numbers to know . Estimate: QPS × payload → bandwidth; rows × size → storage.
Practice map
URL shortener · rate limiter · cache — warm-ups Dropbox · YouTube — storage / media News feed · chat — fanout & delivery Ticketmaster / auction — contention & booking Notification platform — queues · priority · dedup → post
05 Behavioral cheat sheet
STAR shape
S — stakes in 2–3 lines (not your biography).T — your job in one breath.A — most of the airtime: decisions, tradeoffs, verbs.R — before → after metric (or crisp qualitative).End with one line: what you’d repeat / change.
Story bank (prepare 6–8):
1. Impact / hard technical problem
2. Conflict or disagreement
3. Failure or incident
4. Mentorship / raising the bar
5. Ambiguity / zero-to-one
6. Cross-team influence
7. Why this company / why leave (tight)
Map each to Leadership Principles / company values.
Calibration
Lead with I on decisions you owned; we for team context. Metrics > adjectives. Approximate honestly (“~30% p99 drop”). Conflict stories need: disagree → listen → decide → own outcome. Never trash a past employer — critique systems, not people. AI / tools: what you used, what you verified, what you’d automate next.
06 Negotiation cheat sheet
Non-negotiables
Starting TC is sticky — raises compound from it. Confirm level early; it pins every band. Ask the band before giving a number when you can. Delay hard numbers until you have a written / verbal offer. Never accept on the call — set a follow-up.One consistent story your recruiter can sell to finance.
Before the loop:
- Walk-away TC: _____
- Happy TC: _____
- Competing timelines: _____
On the verbal:
1) Thank + excitement
2) Confirm level + location + start flexibility
3) Ask for full breakout (base / bonus / equity / sign-on / refresh)
4) “I’d like to review overnight and reconnect [day].”
Counter (email/call):
- Anchor to market + competing signal (honest)
- Ask for specific lever(s): base / RSU / sign-on
- Stay warm; give them a path to yes
Levers
Base · bonus · equity (grant + vest) · sign-on · refresh · relocation · PTO Level up > small cash when close — multi-year impact. HM = ally on level/scope; recruiter = process; finance = calculator. Don’t negotiate with the wrong person or change your story mid-stream.
07 Day-of pocket card
Five lines
Coding: pattern → invariant → complexity → code → dry run.LLD: spec → entities → APIs → walkthrough → race + extend.HLD: clarify → API → working boxes → NFR deep dive.Behavioral: short S/T · long A · measured R.Offer: band · breakout · overnight · one story.