First read the notes and credits. Then, enter the number of times you want the three people to play the game and observe the results. Don't enter anything that is not a number. This is 1s1s.
This is a model that simulates problem 30 of the 2002 National MathCounts Sprint Round. The problem says that 3 people (P1, P2, and P3) take turns flipping a coin in that order. If someone gets heads they win and the game is over. If they get tails, the next person flips the coin (if P3 gets tails then P1 goes again). It asks what the probability is that the third person will win. The answer is 1/7 and I wanted to prove that the more times the game is played, the closer the third person is to winning 1/7 of the time. The difference represents in total how far off the three players are from they "should" get, for example if they play 7,000 times it would be 4,000, 2,000, and 1,000.