Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Let's say I have a bag with numbered slips of paper from 0 to 10. If I draw a 0 then I stop adding to the sum and return the sum. Else I add the number I draw to the current sum and place the slip back in the bag. I keep doing this until I draw the 0 slip. (The initial sum is 0).

What would be the expected value of the sum?

So this is what I've been trying to do.

I let $S$ = the total sum, $X_i $ = the ith slip drawn.

$$\operatorname{E}[S] = \operatorname{E}[\operatorname{E}[S\mid X_1]] $$

$$\operatorname{E}[S] = \sum\limits_{i=1}^{10} \operatorname{E}[S \mid X_1 = i] * \operatorname{P}(X_1 = i) $$

This is the part where I'm a bit confused.

Am I correct to say that $\operatorname{E}[S\mid X_1 = 1] $ is equal to $1 + \operatorname{E}[S] $ and so on?

share|cite|improve this question
Edited with my attempt – user1698555 Nov 2 '12 at 0:51
up vote 3 down vote accepted

You are correct to say that "$\operatorname{E}[S\mid X_1 = 1] $ is equal to $1 + \operatorname{E}[S] $ and so on".

You have a chance of $\frac{10}{11}$ of getting a positive number, and if you do then you expect to add an average of $\frac{11}{2}$ and trying again. So


which is easy to solve.

share|cite|improve this answer
Thanks, I just wanted to make sure my reasoning was correct. – user1698555 Nov 2 '12 at 1:05

Hint: Let $X_n$ be the $n$'th number drawn (or $0$ if you stop before drawing $n$ numbers). The expected value of the sum is $\sum_{n=1}^\infty E[X_n]$.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.