← All problemsSign in

Chef and Water Car

CodeChefRating 1683Open on judge ↗

Chef is a great mechanic. As the cost of petrol is increasing day by day he decided to build a water car to take his girlfriend Natasha on a date. Water car has great build quality but is able to travel only $1$ Km on every $1$ liter of water. To show off his water car to Natasha he took her to the formula racing track which is an ($N-1$) km long road with checkpoints numbered $1$ to $N$ from left

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.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start