Path With Minimum Effort
MediumLeetCodeShortest Paths & Topological Sort
Approach hintTry it first, then revealHide
The cost of a route is its largest single step rather than a sum, yet Dijkstra still applies: relax a neighbour with max(effort so far, step). Binary search on the effort with a BFS check is a valid alternative.