Question 871844
40 miles in 2 hours so 

speed with current = 40/2.5 = 16 mph

speed of current = 2 mph

so speed of boat in still water = 16-2 = 14 mph

when travelling upstream the speed will be 14-2 = 12 mph

t= 40/12 = 3.33 hours