© 26 January 2023 by Michael A. Kohn
Link to the pdf if this article
Introduction | Coin Problem | Bayes’s Rule: History | Bayes’s Rule: Derivation | Billiards Problem | Endnotes | References

Coin Problem
Many years ago, I was asked in a job interview to solve the following problem:
A bag contains three coins: one fair coin, one 2-headed coin, and one 2-tailed coin. One of the three coins is selected and flipped. It shows heads. What is the probability that it is the 2-headed coin?
In this problem, the hypothesis is that the selected coin is 2-headed. The observation is that it comes up heads on a single toss. To solve the problem, we calculate one unknown probability from three known probabilities.
The unknown probability is the probability of having selected the 2-headed coin given that it comes up heads on a single toss:
P(2-headed|heads).
The three known probabilities are:
1) the probability that it comes up heads given that it is the 2-headed coin, P(heads|2-headed)=1, 2) the probability of selecting the 2-headed coin, P(2-headed)=13, 3) the overall probability of heads,
P(heads)=P(heads|fair)×13+P(heads|2-headed)×13+P(heads|2-tailed)×13P(heads)=(12×13)+(1×13)+(0×13)=12.The formula used for this calculation is universally known as “Bayes’s Theorem” or “Bayes’s Rule”. (If you think I should be punctuating the possessive in some way other than “Bayes’s”, see Endnote #1.) I will give a general version of Bayes’s Rule in the next section. For this problem, it is:
P(2-headed|heads)=P(heads|2-headed)×P(2-headed)P(heads)=1×1312
In the interview, I didn’t simplify the answer to 23, but the interviewer passed me to the next level anyway.