Catch me if you can!
CodeChefOpen on judge ↗
Webber is a police commander. A thief wants to escape. Webber is standing at police station, $0$. The thief is standing at $X$ on the x-axis. The thief starts to run with speed $v_b$ to right, and Webber starts to catch him with speed $v_a$ . When he catches the thief, he comes back to 0 with speed $v_a$. How much time will it take for Webber to catch the thief and back to the police station? ###
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