# Flipping a coin

Two players, $A$ and $B$, alternately and independently flip a coin and the first player to get a head wins. Assume player $A$ flips first. If the coin is fair, what is the probability that $A$ wins?

So $A$ only flips on odd tosses. So the probability of winning would be $$P =\frac{1}{2}+\left(\frac{1}{2} \right)^{2} \frac{1}{2} + \cdots+ \left(\frac{1}{2} \right)^{2n} \frac{1}{2}$$

Is that right? It seems that if $A$ only flips on odd tosses, this shouldn't matter. Either $A$ can win on his first toss, his second toss, ...., or his $n^{th}$ toss. So the third flip of the coin is actually $A$'s second toss. So shouldn't it be $$P = \frac{1}{2} + \left(\frac{1}{2} \right)^{2} + \left(\frac{1}{2} \right)^{3} + \cdots$$

-
Think of it like this: A and B both throw a coin. If $A$ gets head, he wins. If $B$ gets head, but $A$ doesn't, $B$ wins. If neither has head, they throw again. $A$ wins in 2 out of 3 events (head-head and head-tail) and $B$ wins in 1 case (tail-head). – Myself Dec 27 '11 at 1:43
Your first idea was right, apart from the fact that you need to sum forever. The second expression for $P$ is not right. The situations in which A wins are (with obvious abbreviations) H, TTH, TTTTH, TTTTTTH, and so on. The probability of each is easy to calculate. add up. The mistake in the second estimate is that it is not only A's tosses that matter. B's coin needs to cooperate by coming up tails. – André Nicolas Dec 27 '11 at 2:15

Let $p$ be the probability that A wins. This can happen in two ways: (i) A wins immediately (probability $1/2$ or (ii) A tosses a tail, but ultimately wins.

If A tossed a tail (probability $1/2$, then in effect B is now "first" so the probability she does not win is $1-p$. We conclude that $$p=\frac{1}{2}+\frac{1}{2}(1-p).$$ Solve for $p$. We get $p=2/3$.

Comment: There are nice expressions for $p$ as infinite geometric series. So we can think of the above argument as a probabilistic method for summing a very particular geometric series. By varying the probability that the coin lands heads, we can use the same idea to find the sum of any infinite geometric series, as long as the "common ratio" is positive.

-

You were on track at first, but the game may go on for a very long time. You should not stop at "$2n$".

$A$ could win on the first flip of the coin, or the third, or the fifth, ...

So, the probability of $A$ winning would be the sum of the probabilities of the events $$A_i = A\text{ wins on the } i^{\rm th}\text{ flip; where }i\text { is odd}.$$

If the coin is fair, $$P(A_i) =\Bigl({1\over2}\Bigr)^{i-1}\cdot{1\over2} =\Bigl({1\over2}\Bigr)^i.$$

Summing the probabilities above, the probability that $A$ wins is $$\sum_{i \text{ odd}} P(A_i)= \sum_{i \text { odd}} \Bigl({1\over 2}\Bigr)^i.$$ The series above can be written: $$\sum_{i \text { odd}} \Bigl({1\over 2}\Bigr)^i= \sum_{i =0}^{\infty} \Bigl({1\over 2}\Bigr)^{2i+1}= {1\over 2}\sum_{i =0}^{\infty} \Bigl({1\over 4}\Bigr)^{ i }={1\over2}\cdot{4\over3}=2/3.$$

You could also solve the problem this way:

Condition on what happens on the first two flips:

$A$ wins if the first flip is a head and the probability that the first flip is a head is 1/2.

$A$ loses if the first flip is a tail and the second ($B$'s turn) is a head. The probability that the first flip is a head and the second a tail is 1/4.

If the first two flips are tails, then given this, the probability that $A$ wins eventually afterwards is the same as the initial probability that $A$ wins. The probability that the first two flips are tails is 1/4.

So $$P(A) =1\cdot{1\over2}+0\cdot {1\over4}+P(A)\cdot{1\over4}.$$

Solving the above for $P(A)$ gives $P(A)=2/3$.

As for your second method, I think you are forgetting that $A$ does not get a second toss if $B$ flips heads on his first toss...

-

the probability that the first head occurs on toss $n$ is $2^{-n}$ so the probability that the first head happens on an odd $n$ is $\sum_{k=0}^{\infty}2^{-(2k+1)}=(1/2)(1/(1-1/4))=2/3$

-

Here is the solution for general p. Let A gets the head in Nth trial to win the game. Since he is flipping the coin in odd trials,

P(N=1) = p, P(N=3) = (1-p)^2 * p, P(N=5) = (1-p)^4 * p, and so on.

Thus P(A wins) = p + (1-p)^2 * p + (1-p)^4 * p + ... = 1/(2-p). If p = 1/2, then P(wins) = 2/3.

-

\mathsrc{A_k}={A losing in his first k tosses and B losing in his first k tosses and A winning in his k+1 toss} \begin{align} P(\text{A winning}) &= P(\text{A winning in his first toss or } \mathrm{A_1} \text{ or } \mathrm{A_2} \text{ or } \ldots)\\ &= P(\text{A winning in his first toss}) + P(\mathrm{A_1}) + P(\mathrm{A_2}) + \dots\\ &= 0.5 + (0.5)(0.5)(0.5) + (0.5)(0.5)(0.5)(0.5)(0.5) + \dots \\ &=0.5 + (0.5)^3 + (0.5)^5 + .........\\ &= \frac{0.5}{1 - 0.25} = \frac{0.5}{0.75} = \frac{50}{75} = \frac{2}{3}\\ \end{align}

-
There were answers with more details, better appearance, with the same final answer. Use Help please. – Hoseyn Heydari Feb 12 '14 at 8:49