Low-level design
Object-oriented design for interviews: the framework, design principles and patterns, concurrency, and problem breakdowns you can practice in the code runner.
Object-oriented design for interviews: the framework, design principles and patterns, concurrency, and problem breakdowns you can practice in the code runner.
| Title | Difficulty |
|---|---|
| Design a Garbage Collector Design a garbage-collected heap with roots, references and automatic collection, compare reference counting with mark-and-sweep, and see why cycles and deep chains shape the design. | Hard |
| Design a Grocery Subscription Service Design a grocery subscription service where customers get a basket every few days, can pause, resume or cancel, and a daily job turns every due subscription into an order. | Medium |
| Design a Hit Counter Design a counter that records hits and reports how many arrived in the last 5 minutes, from a growing list to a queue to a fixed ring of 300 one-second buckets, plus per-page counts and thread safety. | Easy |
| Design a Hotel Management System Design a hotel front-desk system with room types, date-range reservations, a check-in and check-out lifecycle, extras on an itemized bill, and early check-out. | Medium |
| Design a Job Scheduler Design a job scheduler that runs immediate, one-off and recurring jobs on a fixed worker pool, with an event loop over timers, clear status tracking, cancellation and room for cron schedules. | Medium |
| Design a JSON/XML Parser Design a parser that reads JSON and a subset of XML into one document tree, with a tokenizer, recursive descent, numbers kept exactly, and a registry that makes formats swappable. | Medium |
| Design a Key-Value Store with Transactions Design a Redis-like in-memory key-value store with expiring keys, nested begin/commit/rollback transactions, and a write-ahead log so committed data survives a crash. | Hard |
| Design a Lead Distribution Engine Design an engine that hands incoming sales leads to agents, with a swappable rule per business unit (round robin, least loaded, skill match), agent capacity and availability. | Medium |
| Design a Leaderboard Design a game leaderboard that adds points to players, sums the top K totals and resets players, from sorting on every read to a heap to an always-sorted score index, plus ranks, daily boards and scale. | Medium |
| Design a Library Management System Design a library system with books and their physical copies, members with loan limits, due dates and late fines, and a first-come-first-served hold queue that keeps returned copies for the next member. | Medium |
| Design a Live Cricket Score App Design a Cricbuzz-style live cricket score app that records every ball, tracks runs, overs, wickets and strike, writes ball-by-ball commentary, lists the schedule and ranks players by career stats. | Medium |
| Design a Load Balancer Design an in-process load balancer with pluggable round robin, weighted, least connections and random picking, health status, and retries that move a failed request to another backend. | Medium |
| Design a Loading Cache Design a thread-safe cache that loads missing values through a loader, runs one load per key when many threads miss at once, expires entries after a TTL, and never caches failures. | Medium |
| Design a Log Storage System Design a log store that saves ids with timestamps and returns every log in a time range at a chosen granularity, from field-by-field checks to one string range over a sorted index. | Medium |
| Design a Logging Framework Design a logging framework with levels, appenders and formatters, an async bounded buffer with backpressure policies and flush, and an audit trail that never loses an entry. | Medium |
| Design a Meeting Room Scheduler Design a meeting room scheduler that books the smallest free room with enough seats, detects time conflicts quickly with sorted bookings, and supports cancels and availability queries. | Medium |
| Design a Memory Allocator Design a malloc-style allocator over a fixed heap with allocate, free and reallocate, first-fit and best-fit placement, block splitting, coalescing of free neighbours, and fragmentation stats. | Hard |
| Design a Message Queue Design a Kafka-like message queue with partitioned append-only logs, key-based partitioning, consumer groups with rebalancing, committed offsets, time-based retention and thread-safe producers and consumers. | Hard |
| Design a Multi-Level Cache Design an L1/L2 cache in front of a slow store, with LRU eviction per level, promotion on reads, write-through and write-back policies, and a distributed version with consistent hashing and quorums. | Hard |
| Design a Multi-Stage Pipeline Design an in-process pipeline whose stages run on their own threads, joined by bounded queues for backpressure, with a poison-pill shutdown that finishes every accepted item. | Medium |