The boat went 5hours upstream, let's say it has a "still water" speed rate of "b", it went 100miles... however, going upstream is going against the current, let's say the current has a speed rate of "c"
so, when the boat was going up, it wasn't really going "b" fast, it was going " b - c " fast, because the current was eroding speed from it
now, when coming down, the return trip, well the length is the same, so the distance is also 100miles, it only took 2hrs though, because, the boat wasn't coming down "b" fast, it was coming down " b + c " fast, because the current was adding speed to it, so it came down quicker
now, recall your d = rt, distance = rate * time
solve for "c", to see what's the current's speed
what's "b"? well 20+c = b