Common Problems
Design Yelp
Try This Problem Yourself
Practice with guided hints and real-time feedback
Understanding the Problem
Functional Requirements
- Users should be able to search for businesses by name, location (lat/long), and category
- Users should be able to view businesses (and their reviews)
- Users should be able to leave reviews on businesses (mandatory 1-5 star rating and optional text)
- Admins should be able to add, update, and remove businesses (we will focus just on the user)
- Users should be able to view businesses on a map
- Users should be recommended businesses relevant to them
Non-Functional Requirements
- The system should have low latency for search operations (< 500ms)
- The system should be highly available, eventual consistency is fine
- The system should be scalable to handle 100M daily users and 10M businesses
- The system should protect user data and adhere to GDPR
- The system should be fault tolerant
- The system should protect against spam and abuse
Constraints
The Set Up
Defining the Core Entities
The API
High-Level Design
1) Users should be able to search for businesses
2) Users should be able to view businesses
3) Users should be able to leave reviews on businesses
Potential Deep Dives
1) How would you efficiently calculate and update the average rating for businesses to ensure it's readily available in search results?
2) How would you modify your system to ensure that a user can only leave one review per business?
3) How can you improve search to handle complex queries more efficiently?
4) How would you modify your system to allow searching by predefined location names such as cities or neighborhoods?
Final Design
What is Expected at Each Level?
Mid-level
Senior
Staff+
Currently up to 25% off
Hello Interview Premium
On This Page
Understanding the Problem
Functional Requirements
Non-Functional Requirements
Constraints
The Set Up
Defining the Core Entities
The API
High-Level Design
1) Users should be able to search for businesses
2) Users should be able to view businesses
3) Users should be able to leave reviews on businesses
Potential Deep Dives
1) How would you efficiently calculate and update the average rating for businesses to ensure it's readily available in search results?
2) How would you modify your system to ensure that a user can only leave one review per business?
3) How can you improve search to handle complex queries more efficiently?
4) How would you modify your system to allow searching by predefined location names such as cities or neighborhoods?
Final Design
What is Expected at Each Level?
Mid-level
Senior
Staff+

Schedule a mock interview
Meet with a FAANG senior+ engineer or manager and learn exactly what it takes to get the job.
