Four people arrive at a river at night. There is a narrow bridge, but it can only hold two people at a time. They have one torch and, because it is night, the torch has to be used when crossing the bridge.
Person A can cross the bridge in one minute, B in two minutes, C in five minutes, and D in eight minutes.
What is the shortest time they all can get across the bridge?
Source : Wikipedia