Design pickup point planning for ride-hailing
Company: Amazon
Role: Software Engineer
Category: System Design
Difficulty: medium
Interview Round: Technical Screen
Design an algorithm and high-level system for recommending a pickup point in a ride-hailing app.
A passenger requests a ride from an approximate city location, such as inside a building or near a large intersection. A driver is at a known GPS location. The system should recommend a safe and practical pickup point for the passenger to walk to and the driver to reach.
### Constraints & Assumptions
- You have access to map data, road graphs, pedestrian paths, routing/ETA services, and real-time traffic when available.
- The passenger GPS pin may be noisy or inside a building.
- The driver must stop legally and safely.
- The pickup point should balance passenger walking time, driver ETA, safety, reliability, and user experience.
- Present the selected point clearly to both passenger and driver.
### Clarifying Questions to Ask
- What city environment is in scope: downtown, suburb, airport, campus, or mixed?
- Is passenger walking ability or accessibility known?
- What is the maximum acceptable walking distance?
- Do we know legal stopping zones, curb access, entrances, and historical pickup success?
- Is the objective minimizing total time, cancellations, unsafe stops, or support contacts?
### What a Strong Answer Covers
- Snapping passenger and driver positions to map/road/pedestrian networks.
- Candidate pickup-point generation near the passenger.
- Filtering unsafe or illegal candidates.
- Scoring candidates using driver ETA, passenger walking ETA, safety, confidence, and historical success.
- System architecture with client apps, backend, map service, routing service, pickup-point service, logging, and model improvement.
- Presentation in both apps and fallbacks for low-confidence cases.
### Follow-up Questions
- How would you handle airports or malls?
- How would you learn better pickup points from historical data?
- How would you support passengers who cannot walk far?
- What metrics would you use to A/B test the pickup algorithm?
Quick Answer: Design a ride-hailing pickup-point planning system. Covers map snapping, candidate generation, driver and passenger routing, safety filtering, scoring objectives, app presentation, architecture, historical learning, and A/B metrics.