Search
⌘K
Get Premium
Leetcode 815. Bus Routes
Given repeating bus routes and start/target stops, find the minimum number of bus rides required to go from source to target (or -1 if impossible). This is solved by modeling routes/stops as a graph (e.g., routes as nodes connected when they share stops) and performing BFS to find the shortest transfer path — note constraints: up to 500 routes and 1e5 total stop entries.
Asked at:
Amazon
Uber
C
Coupang
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
All Regions
Mid October, 2025
C
Coupang
Staff
https://leetcode.com/problems/bus-routes/
Early July, 2025
Uber
Senior
Mid January, 2025
Amazon
Senior
Comments
Hello Interview Premium
Your account is free and you can post anonymously if you choose.