These are 12 popular system design questions. Each question requires you to consider how its core engineering requirements can be fulfilled.
Since these requirements are (largely) mutually-exclusive, you see a diverse set of engineering patterns while solving them. These patterns help solve problems in both interviews and real-world design discussions.
1. Design a ticket booking system like IRCTC
This mock interview is better than other interviews on youtube because Gaurav is thinking off the bat over here. You can see him struggling with issues and eventually coming up with solutions. Also, kudos to Keerti for making very valid points wherever needed.
2. Design a social media app like Instagram
This video is about designing Instagram for a system design interview. We are expected to design the server side so that all four mentioned features can be incorporated. System Design interviews evaluate a candidate's computer science fundamentals, architecture principles, etc.
We start by building an entity relationship diagram. Here the columns are defined according to the requirements. We then move to design a microservice architecture. Each microservice defines a single component of the system.
The newsfeed is built step by step with concepts like load balancing and caching as prerequisites. This completes the system design for Instagram.
3. Design an anomaly detection system like PagerDuty
Production alerts are a vital way engineers monitor their services' health. The alerts are fired when important service metrics behave irregularly. An example would be a sudden spike in the number of errors or a crash in the number of running processes.
We design a system to allow important server metrics to be published, analyzed, and acted upon. The metrics are sent using sidecars in a service mesh. The metrics are then capped and run through machine learning algorithms like isolation trees to search for anomalies.
4. Design a chat application like WhatsApp
The Whatsapp system architecture is a standard system design interview question. This interview question asks us to select features like sending chat messages, reading receipts, group messaging, and last-seen visibility.
The chat system must be scalable and have other non-functional requirements like message ordering, retrial, idempotency, load balancing, and image sharing.
5. Design a cab-aggregation service like Uber
The video by Gaurav Sen explains the high-level design of a cab aggregator system, using Uber as an example.
The system design is centered around a user who books a cab from point A to point B, and the use case can be extended to other apps such as food delivery and pick-up/drop-off services. The video explains the challenges in pricing, search pricing, and matching, which are all important components of a successful cab aggregator system.
The system relies on real-time calculations to determine the price, dynamic search pricing, and efficiently matching drivers with riders.
6. Design a food-aggregation service like Doordash
We go through a popular interview question: Design Doordash.
The system design of Doordash (similar to Swiggy and Zomato in India) involves matching food orders to riders. A rider has to be selected based on their location proximity to the restaurant (since the time taken to deliver an order from restaurant to customer will stay the same on the rider).
For this, we shard geographical locations using hashes, known as Geo-Hashing. An area can be recursively broken down using a geo hash. Riders within a GeoHash region can be asked to pick an order on demand.
Tracking a delivery is done using server-side events or WebSockets. I suggested the idea of WebRTC for this, but it seems like overkill. Let me know your thoughts :D
7. Design a Maps Service Like Google Maps
The video discusses the system design of a map application like Google Maps, which estimates arrival times and provides the best possible routes.
The primary responsibility of the application is to track the user's location and update them with the best possible routes. It also discusses adding locations and finding nearby stores, like restaurants and gyms.
Searching for nearby locations is filtered using a Cartesian distance, and ETA is an important feature. Traffic updates and estimated time of arrival is also important.
Here is what we will be covering:
a. Finding the best route from a source to a destination b. Adding Locations in the map c. Finding Nearby Stores d. Notifying users of traffic updates e. Calculating the estimated time of arrival
8. Design a turn-based online-gaming service like Chess
We set the following requirements to design a chess website:
- Users can declare challenges and accept game challenges.
- A user should be able to play a game with another user.
- Users can analyze their games later.
- Optional (Users can spectate games)
- Optional (The system should identify cheaters and ban them)
Non-functional requirements:
- The gameplay should be smooth and have low latency.
- The system must be fault tolerant.
9. Design a documentation system like Google Docs
This design is about:
- Storing, retrieving, and editing documents
- Sharing permissions: READ, EDIT, LINK-SHARING
- Notifications on email
- Version History
- Spell Checking
- Comments Support
- Offline and Collaborative Editing
10. Design an emailing service like GMail
A detailed design that explains:
- Request flows
- Gateway checks
- Session management
- Profile registration
- API contracts
- Email sending
- Spam detection.
11. Design a live-streaming broadcast app like ESPN
We define the product and engineering requirements of a live streaming system. Primarily, they are:
- Ingest live HD video.
- Transform video for different users.
- Transport videos to end users.
12. Design a data pipeline using map-reduce architecture
MapReduce is a technique for processing large datasets using parallel computers at scale. Programs in this functional style are automatically parallelized and executed on a large cluster of commodity machines.
Designing such a model requires understanding asynchronous processes, fault tolerance, data processing, and scalability.
The above questions are a list of common system design questions asked at product and big tech companies. Be sure to follow us for the latest updates and new interview solutions!
You can also enroll in our up-to-date system design course at InterviewReady.
Cheers!