Probability of not losing the game Jake flips a biased coin with a probability of $p=0.7$ for $H$, until the coin shows $H$. The number of coin flips then determine the amount of coins Jake is allowed to pull out of a jar, with replacement, that contains 100 coins out of which 25 are real and 75 a fake. For each real coin Jake pulls out of the jar, he receives $10.
Assuming that Jake pays $20 for participating in this game, what is the probability that he didn't lose money?
 A: Let $X$ denote the number of flips. 
There will be no loss if at least $2$ real coins are pulled out and
denoting this event with $E$ we find:
$$P\left(E\mid X=k\right)=1-\left(\frac{3}{4}\right)^{k}-k\left(\frac{1}{4}\right)\left(\frac{3}{4}\right)^{k-1}$$
So that:
$$P\left(E\right)=\sum_{k=1}^{\infty}P\left(E\mid X=k\right)P\left(X=k\right)=$$$$\sum_{k=1}^{\infty}\left[1-\left(\frac{3}{4}\right)^{k}-k\left(\frac{1}{4}\right)\left(\frac{3}{4}\right)^{k-1}\right]\left(\frac{3}{10}\right)^{k-1}\left(\frac{7}{10}\right)$$
A: Some ideas to get you started with:
If $\;X\;$ is the Random Variable (RV) that gives us the number of flippings until $\;H\;$ appears, then we have a geometric distribution here:
$$p_X(k):=P(X=k)=(0.3)^{k-1}(0.7)\;\;,\;\;\;k\in\{0,1,2,...\}$$
If $\;Y_k\;$is the RV that gives us the ammount of real coins we pull out in $\;k\;$ tries with replacement, then it distributes binomial and
$$p_{Y_k}(t):=P(Y_k=t)=\binom tk \left(\frac14\right)^t\left(\frac34\right)^{k-t}$$
You may now want to consider one more RV that gives you the profit a gambler makes in this game, and then consider its expectation.
A: He has to pick at least 8 coins from the jar in order to not to lose money, so $k\ge 8$ is the necessary condition.
Hence, the possibility not to lose money is:
$\displaystyle P(X\ge 8)=1-\sum_{k=1}^{7}(0.3)^{k-1}(0.7)$.
