A fair coin is continually flipped until heads appears for the 10th time. Find the number of expected tails A fair coin is continually flipped until heads appears for the 10th time. Find the number of  expected tails.
Im very lost in this problem, can someone help? I think I have to use neg binomial, but not sure, any help will be appreciated!
 A: Informally, it will take 20 flips on average to get 10 heads since there is half a chance that it will be heads on every flip. You should, in that time, see $20-10 = 10$ tails. More rigorously:
Out of a total of $k+10$ flips, we want $k$ to be tails. The last flip must be a heads, so we have to choose $k$ places for the tails from $k+10-1 = 9 +k$ in $\binom{9+k}{k}$ ways. Heads and tails are equiprobable, so we have the appropriate exponent of $0.5$ in each case. Thus the probability of exactly $k \geq 0$ tails being seen before the 10th heads is $\binom{9+k}{k}\cdot 0.5^{10}\cdot 0.5^k$. The expected number of tails is
$$
\begin{align}
\sum_{k=0}^{\infty} \binom{9+k}{k}\cdot 0.5^{10}\cdot 0.5^k \cdot k &= 0.5^{10}\cdot \sum_{k=0}^{\infty} \binom{9+k}{k}\cdot 0.5^k \cdot k \\
&= 0.5^{10}\cdot \sum_{k=0}^{\infty} \frac{(9+k)!}{k!\,9!}\cdot 0.5^k \cdot k \\
&= \frac{0.5^{10}}{9!}\cdot \sum_{k=0}^{\infty} (k+9)\dotsm (k+1)k\cdot 0.5^k
\end{align}
$$
I do not know how to simplify this sum by hand, but WolframAlpha tells me that it evaluates to $9.99\ldots$ or almost 10. So you would expect to see 10 tails before the 10th head.
Edit: I do know how to figure this sum out using hypergeometric series. It turns out that $\sum_{k=0}^{\infty} (k+9)\dotsm (k+1)k\cdot 0.5^k$ can be rewritten as $\sum_{k=0}^{\infty} \frac{2}{10!}(k+1)_{10}0.5^{k+1}$. The hypergeometric form makes the original sum $S = \frac{10!}{2}\,{}_1\!F_0[11;;0.5\,] = \frac{10!}{2}(0.5)^{-11}$. So the expected number is
$$\frac{0.5^{10}}{9!}\cdot \frac{10!}{2}(0.5)^{-11} = 10$$
which works out perfectly.
A: Let $e$ = expected number of tails till first head.
Either you get heads on first toss with $Pr=1/2$ or need $e$ more tosses with $Pr= 1/2$
Thus $e = \frac12(1 +e) \to e = 1$
This is also the expected number of tails till the next head,  thus ans $=10$  
A: 
GrahamKemp, Could you expand on that a bit? I didn't understand the part about the variables having a geometric distribution. – shardulc

Sure.   By definition: a (zero-based) geometric random variable is a count of failures before the first success in an indefinite sequence of iid Bernoulli trials.   So if a fair coin is flipped indefinitely, the count of tails before the first head has a Geometric$_0(1/2)$ Distribution.   And so too does the count of tails between the first and second head, and so on.
Let $T_1$ be the count of tails before the first head, and $T_k$ the count of tails between the $k-1$ and $k$-th heads.
$$T_k~\sim~\mathcal{Geo}_0(1/2)~\iff~ \mathsf P({T_k}=t)~=~\tfrac {1}{2}(1-\tfrac 12)^{t}~=~(\tfrac 1 2)^{t+1}$$
The expectation of such a random variable is $$\begin{align}\mathsf E(T_k)~=~&\tfrac{1-\tfrac 12}{\tfrac 12}\\[1ex]~=~&1\end{align}$$
Now if we count tails until the first head, then repeat times ten, we have counted of tails until the tenth head.   Thus this is a sum of the ten iid geometric random variables.  $~T~=~\sum_{k=1}^{10}T_k$
Hence by the Linearity of Expectation the expected count of tails before the tenth head is: $$\begin{align}\mathsf E(T)~=~&\sum_{n=1}^{10}\mathsf E(T_k)\\[1ex]~=~&10\end{align}$$
That is all.
$\Box$
A: You thought right. The negative binomial distribution is defined as a discrete probability distribution of the number of successes in a sequence of independent and identically distributed Bernoulli trials before a specified (non-random) number of failures (denoted $r$) occur. 
Now assuming the formula for the expected value is given by $\frac{r}{p}$ and the probability of success is $p=0.5$, number of successes is $r=10$ we get for $X \sim Nbin(r=10,p=0.5)$
$$ \mathbb{E}\left[ X \right] = \frac{r}{p} = 10/0.5 = 20.$$
Therefore it takes in expectation 20 number of throws before 10 successes are observed. If we would assume heads to be a succes we see that in expectation the number of tails (failures) is given by 10.
You can also see this if you would create a Monte Carlo simulation.
A: Let $t_i$ be the number of tails between the $i$-th head and the previous one. Then we are looking for $E(t_1 + t_2 + \cdots t_{10}) = 10 \, E(t_i)$
But $E(t_i)=1$ ($t_i$ follows  a geometric distribution - number of failures before the first success - its mean is $p/(1-p)$ where $p$ is the probability of "success", $p=1/2$ in our case - proof here). Hence the expected number of tails is $10$.
