Back to Brain Tonic
AlgorithmsmediumBT-021
#21 Torch and Bridge
Four people need to cross a bridge at night. They have only one torch. The bridge can hold at most two people at a time. The torch must be carried back and forth. Crossing times:
| Person | Time (min) |
|---|---|
| A | 1 |
| B | 2 |
| C | 5 |
| D | 8 |
What is the minimum total time for all four to cross?