Watch two trains with identical programs meet on an infinite railway line, using only local information and an expanding search pattern.

Railway Line Simulation

🪂
P1(0)
🪂
P2(10)
🚂
T1(0)
🚂
T2(10)
Position: -10Position: 5Position: 20

Train 1 Stats

Position: 0
Round: 1
Step in Round: 0
Total Steps: 0

Train 2 Stats

Position: 10
Round: 1
Step in Round: 0
Total Steps: 0

Controls

Simulation Speed
Initial Distance Between Trains
units

💡 How it works

Both trains execute the same algorithm: they explore increasingly farther from their parachute in both directions. In each round, they double their search distance. This exponential growth guarantees they will eventually collide, no matter the initial distance.