A hat contains 100 coins where 99 are fair but one is double
A hat contains 100 coins, where 99 are fair but one is double-headed (always landing Heads). A coin is chosen uniformly at random. The chosen coin is flipped 7 times, and it lands Heads all 7 times. Given this informtion, what is the probability that the chosen coin is double-headed? (of course, another approach here would be to look at both sides of the coin- but this is a metaphorical coin).
Solution
Note that
P(7 consec heads) = P(fair) P(7 consec heads|fair) = P(not fair) P(7 consec heads|not fair)
= (99/100)(1/2)^7 + (1/100)(1^7)
P(7 consec heads) = 0.017734375
Now,
P(7 consec heads and not fair) = P(not fair) P(7 consec heads|not fair) = (1/100)(1^7) = 0.01
Thus, as
P(not fair|7 consec heads) = P(7 consec heads and not fair) / P(7 consec heads)
= 0.01 / 0.017734375
= 0.563876652 [ANSWER]

