Problem 815 · Hard

Bus Routes

Breadth-first search over stops, boarding each bus at most once, counting buses taken.

Open the interactive visualisation