0 day streak

X (Twitter) low-level design interview

Big techProduct Global

You design and build a small working system in code: classes, interfaces, data structures and how they change when a new requirement arrives. In India, the 90-minute machine coding round (Flipkart, PhonePe, Swiggy, Razorpay) is often the first filter for SDE 2.

0%ready

X (Twitter) has no separate low-level design round at any level. Candidates report these object-oriented design problems inside coding rounds and, at senior levels, the design round, so practise them as coding problems: a clean class model, then working code.

ProgressProblem as candidates report itNext step
Process messages from many threads in timestamp order (LLD)Covered by the lesson: Producer-consumer and thread pools Learn it
Implement a key-value map from scratch (LLD)Class diagram, Java code and follow-ups Start
Build a playlist app in 45 minutes (machine coding)Being added: class diagram, Java code and follow-ups Coming soon
Merge two directory trees into one (machine coding)Being added: class diagram, Java code and follow-ups Coming soon
Count engagement over a reply graph with DFS, then parallelize it with threads (machine coding)Being added: class diagram, Java code and follow-ups Coming soon
Simple Twitter model with users, tweets and follower lists (LLD)Being added: class diagram, Java code and follow-ups Coming soon

How X (Twitter) runs it

  • Build five classic systems end to end under a 90-minute timer: parking lot, splitwise, snake and ladder, rate limiter, in-memory key-value store.
  • Separate models, services and storage; keep the main method thin.
  • Learn when to use strategy, factory and observer patterns, and when not to.
  • Handle invalid input explicitly: graders check validation.

The low-level design round, scored by level · New to LLD? Start with OOP, SOLID and the design patterns, then the machine coding problems.

Questions people ask

Does X (Twitter) have a low-level design or machine coding round?

Not as a fixed round, but candidates report object-oriented design questions: Process messages from many threads in timestamp order (LLD); Implement a key-value map from scratch (LLD); Build a playlist app in 45 minutes (machine coding); Merge two directory trees into one (machine coding); Count engagement over a reply graph with DFS, then parallelize it with threads (machine coding); Simple Twitter model with users, tweets and follower lists (LLD).