in a river flowing at 2 km / hr , a boat travels 40 km upstream and then returns downstream to the starting point . if its speed in still water be 6 km / hr , find the total journey time .
"explanation : speed of the boat = 6 km / hr speed downstream = ( 6 + 2 ) = 8 km / hr speed upstream = ( 6 - 2 ) = 4 km / hr distance travelled downstream = distance travelled upstream = 40 km total time taken = time taken downstream + time taken upstream = ( 40 / 8 ) + ( 40 / 4 ) = 15 d"
add(divide(40, subtract(6, 2)), divide(40, add(6, 2)))