You will solve a pair in and by changing letters, and turn the times of a boat into its speed and the speed of the stream. The function solve_pair is written for you.
Your tasks.
solve_recip, solve and . Let and , solve for and with solve_pair, and return (1 / u, 1 / v).boat_speeds, return (boat, stream) in km/h. The speed downstream is the distance divided by hours_down, the speed upstream is the distance divided by hours_up, and the two speeds give the boat and the stream.ans to the speed of the boat when km downstream takes hours and km upstream takes hours.Have you tried it?
Do the tasks in the editor first, and run the checker after each one. Its hints help when a check fails. When you are ready, compare your code with this solution.
Log in to join the discussion.
Loading…