Understanding a question that asks for probability of flips of coins

probability

Independent flips of a coin that lands on heads with probability $p$
are made. What is the probability that string THHH occurs before the
string $HHHH$?

Attempt

I have a little trouble understanding this problem. I realize we can use conditional probability

$$ P(HHHH \mid THHH ) = \frac{P(HHHH \cap THHH) }{P(THHH)} $$

How to understand the event $HHHH \cap THHH$? this is basically saying that we obtain string HHHH and THHH which cannot happen at the same time. Is the probability im trying to find correct?

Best Answer

One of THHH or HHHH must occur first - it is impossible for neither to ever occur.

Complementary counting gives us

$$P\,\big(\text{THHH occurs before HHHH}\big) \,\,= \,\,1-P\,\big(\text{HHHH occurs before THHH}\big)$$

In order for HHHH to occur before THHH, the first four flips must all be H (think about why this must be the case). Given that, we can rewrite

$$ \begin{align*} P\,\big(\text{THHH occurs before HHHH}\big) \,\,&= \,\,1-P\,\big(\text{first four flips are all heads}\big)\\\\ &= \,\,1 - \left(\frac{1}{2}\right)^4\\\\ &= \,\,1 - \frac{1}{16}\\\\ &= \,\,\boxed{\,\frac{15}{16}\,\,} \end{align*} $$


If the coin is weighted with probability of heads $p\neq 1/2$, simply substitue $p$ for $1/2$ in the above calculation.

Related Question