Recommended Structure:

  1. Requirements (5 mins):
  1. Capacity Estimation: Skip unnecessary calculations unless they directly impact the design (e.g., sharding in a TopK system).

  2. Core Entities (2 mins): Identify key entities (e.g., User, Tweet, Follow) to define the system's foundation.

  3. API/System Interface (5 mins): Define the contract between the system and users. Prefer RESTful APIs unless GraphQL is necessary.

  4. [Optional] Data Flow (5 mins): Describe high-level processes for data-heavy systems (e.g., web crawlers).

  5. High-Level Design (10-15 mins): Draw the system architecture, focusing on core components (e.g., servers, databases). Keep it simple and iterate based on API endpoints.

  6. Deep Dives (10 mins): Address non-functional requirements, edge cases, and bottlenecks. Proactively improve the design (e.g., scaling, caching, database sharding).

flow chart

Tips:

  1. Avoid overcomplicating the design early on.

  2. Communicate clearly with the interviewer, explaining your thought process and data flow.

  3. Focus on relevant fields in the data model, not every detail.

  4. Balance proactive discussion with listening to the interviewer’s probes.

Example: Twitter System Design

  1. Functional Requirements: Post tweets, follow users, view feeds.

  2. Non-Functional Requirements: High availability, low latency (<200ms), scalability to 100M+ DAUs.

  3. Core Entities: User, Tweet, Follow.

  4. API Endpoints: POST /v1/tweet, GET /v1/feed, etc.

  5. Deep Dives: Discuss fanout-on-read vs. fanout-on-write, caching, and horizontal scaling.