#40Hard
Find a Rider for Uber or Uber Eats
Asked by:FacebookUberGoogleMicrosoft
Recommended Solutions from the Web
Excellent article on geospatial algorithms
https://blog.mapbox.com/a-dive-into-spatial-search-algorithms-ebd0c5e39d2a
Good solution for Yelp, which applies here
https://systemdesignschool.io/problems/yelp/solution
Popular Video
https://www.youtube.com/watch?v=M4lR_Va97cQ
Mock Interview
https://www.youtube.com/watch?v=atywHEArk1w
Key Details & Edge Cases You Should Know
•
Very similar to Proximity Service (Find Nearby Friends). This problem is about maintaining a large geospatial index.
•
How do you maintain a geospatial index of drivers?
•
In that index, how do you update the driver location quickly?
•
How do you remove the driver as soon as you match a rider? You don't want the driver to be matched at the same time.
•
How do you ensure efficient edits - when a driver location changes, your algorithm should update the index fast.