Greedy Uber Driver
CodeChefOpen on judge ↗
An uber driver is in a very greedy mood and wants to earn as much money as possible, through the UberGo he's driving. The city he drives in is a very organised manner and only has $N$ fixed spots where the riders can start and end the trip. He starts from spot $X$ and wants to finally end at spot $Y$. Now Uber has introduced a new policy due to which he simply can't go on doing as many trips
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start