← All animations

๐Ÿšช The Monty Hall Problem

Three doors. Behind one is a car; behind the other two, goats. You pick a door. The host โ€” who knows where the car is โ€” opens a different door to reveal a goat, then offers you the chance to switch to the last unopened door. Should you? The answer feels wrong but it isn't: switching doubles your odds. Play a game, then let the computer prove it 1000 times over.

1. Play a game โ€” pick, watch the reveal, then stay or switch

Click a door to pick it. The host opens a goat door from the ones you didn't choose. Then decide: stay with your pick or switch to the other closed door. The tallies below track how each strategy is doing.

Pick a door to begin.
If you STAY
0/0 โ€” %
If you SWITCH
0/0 โ€” %

2. The convincer โ€” simulate thousands of games

One game proves nothing โ€” luck swamps it. So let's play it out automatically. Each round we deal a fresh game, run both strategies on it, and chart the win rates. Watch them lock onto 1/3 for staying and 2/3 for switching.

0 games played

3. Why switching wins

The trick is that the host isn't acting randomly โ€” he knows the doors and is forced to dodge both the car and your pick. That forced choice leaks information onto the door he leaves closed.

Still not convinced? Crank up the number of doors. With N doors the host opens all but one of the others โ€” and switching wins (Nโˆ’1)/N of the time. At 100 doors, staying is a 1% shot; switching is a 99% near-certainty.

Stay 33.3% ยท Switch 66.7%