Common Problems
Design a Business Review Service like Yelp
Evan King
medium
35 min
Understanding the Problem
Functional Requirements
Some interviewers will start the interview by outlining the core functional requirements for you. Other times, you'll be tasked with coming up with them yourself. If you've used the product before, this should be relatively straight forward. However, if you haven't, it's a good idea to ask some questions of your interviewer to better understand the system.
Here is the set of functional requirements we'll focus on in this breakdown (this is also the set of requirements I lead candidates to when asking this question in an interview)
Core 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)
Below the line (out of scope):
- 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
Core 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
Below the line (out of scope):
- The system should protect user data and adhere to GDPR
- The system should be fault tolerant
- The system should protect against spam and abuse
Here is what you might write on the whiteboard:
Schedule a mock interview
Meet with a FAANG senior+ engineer or manager and learn exactly what it takes to get the job.
© 2024 Optick Labs Inc. All rights reserved.