Suppose that we flip a fair coin until either it comes up ta
Suppose that we flip a fair coin until either it comes up tails twice or we have flipped it six times. What is the expected number of times we roll the die?
Solution
Let X be random variable \'number of times \' the roll will die
Here X takes values 2,3,4,5 and 6
when X=2; the first two flips are tails
X=3 ;one tail in first two flips and last flip is tail ; X=4 there is one tail in the first three flips and last flip is tail
X=5 ; one tail in the first four flips and fifth one is tails ; X=6 ; first five flips only one tail or no tail and then experiment stopped
probability of a head =1/2 ; probability of a tail = 1/2
Expected number of times is 3.75
| x | P(x) | xP(x) |
| 2 | 0.25 | 0.5 |
| 3 | 0.25 | 0.75 |
| 4 | 0.1875 | 0.75 |
| 5 | 0.125 | 0.625 |
| 6 | 0.1875 | 1.125 |
| 3.75 |
