Advertisements
Recent

[Brainteaser] The Monty Hall Problem

Suppose you’re on a game show and you’re given the choice of three doors. Behind one door is a car; behind the others, goats. The car and the goats were placed randomly behind the doors before the show. The rules of the game show are as follows: After you have chosen a door, the door remains closed for the time being. The game show host, Monty Hall, who knows what is behind the doors, now has to open one of the two remaining doors, and the door he opens must have a goat behind it. If both remaining doors have goats behind them, he chooses one randomly. After Monty Hall opens a door with a goat, he will ask you to decide whether you want to stay with your first choice or to switch to the last remaining door. Imagine that you chose Door 1 and the host opens Door 3, which has a goat. He then asks you, ‘Do you want to switch to Door Number 2?’ Is it to your advantage to change your choice?

Interview Questions

Answer: Most people assume that each door has an equal probability (1/3) and conclude that switching does not matter. Actually, the player should switch – doing so doubles the probability of winning the car from 1/3 to 2/3.

Let’s say Door 1 is the winning door. Look at the outcome for each door that the player could pick and decide to switch.

  1. Picks Door 1 (win). Monty shows Door 2 or 3 with goat. Player switches, and loses
  2. Picks Door 2 (goat). Monty shows Door 3 with goat. Player switches, and wins
  3. Picks Door 3 (goat). Monty shows Door 2 with goat. Player switches, and wins

Two of the three scenarios are wins if the players switches, so therefore there is 2/3 probability that the player wins if he switches.

Put another way, the probability that the player initially chooses the winning door is 1/3, since there are 3 doors each of which has an equal chance of concealing the car. The probability that the door Monty Hall chooses conceals the car is 0, since he never chooses the door that contains the prize. Since the sum of the three probabilities is 1, the probability that the prize is behind the other door is 1 – (1/3 + 0), which equals 2/3. Therefore, switching is more advantageous due to the doubled probability.

Image Source: Open Data Science

Advertisements