Cheapest Flights Within K Stops

Asked at Apple · Coding Questions · Difficulty: Medium · Last asked Apr 25, 2026

There are `n` cities, numbered `0` to `n - 1`, connected by one-way flights. Find the cheapest way to travel from a source city to a destination city when the number of stops is limited.

Loading the problem…