Bite 3.5.5 · Modelling Challenges

Crossing the Bridge at Night

How to get 4 people across a dark bridge in the shortest time possible?

Image by Rezuanur Rahman Mubin · Unsplash

The Bridge and Torch Problem is a classic logic puzzle made famous by tech job interviews at companies like Microsoft and Google.

The intuitive trap of the puzzle lies in assuming that the fastest person should always act as the group’s “shuttle driver”, escorting others across and returning with the torch. However, when the speed differences among group members are large, this strategy is sub-optimal.

Imagine four people (A, B, C, and D) standing on the left bank of a river at night, needing to cross to the other side via a narrow, dangerous bridge. The rules for crossing are:

  1. Individual Speeds: Each person takes a different amount of time to cross the entire bridge:
    • Person A: 1 minute.
    • Person B: 2 minutes.
    • Person C: 5 minutes.
    • Person D: 10 minutes.
  2. Bridge Capacity: The bridge can hold at most two people at a time.
  3. Torch Requirement: It is dark, and they have only one shared torch. To cross safely in either direction, the group crossing must carry the torch at all times.
  4. Walking Pace: When two people cross together, they walk at the pace of the slower person.

The key question to answer is: What is the minimum total time required for all four people to reach the other side?


This puzzle can be formulated systematically as a Mixed Integer Linear Optimization model. Care to give it a try?

Keep following the series

← Previous · 3.5.4Map Coloring Modelling Challenges Next · 3.5.6 →Hidato

How to cite

Cite this post

Martín-Campo, F. Javier (2026). Crossing the Bridge at Night. https://www.fjmartincampo.com/blog/2026/bridgecrossing/

As a BibTeX entry:

@misc{martín-campo2026crossing-the-bridge-at-night,
  title   = {Crossing the Bridge at Night},
  author  = {Martín-Campo, F. Javier},
  year    = {2026},
  month   = {may},
  url     = {https://www.fjmartincampo.com/blog/2026/bridgecrossing/}
}

This post is published under a CC BY-NC-SA 4.0 license.