Bridge and torch problem
People must cross a bridge at night with one flashlight. At most two cross at once, a pair moves at the slower person's speed, and someone has to bring the flashlight back. Given everyone's crossing time, return the minimum total time. Sort the times and compare the two ways of moving the two slowest people across at each step.
No answer yet. Write the first one; the best answer gets endorsed.
