Probability you run out of white balls first

probability

I saw this question online (interview brainteaser prep), and can't get my head around it.

You have $r$ red balls, $w$ white balls in a bag. If you keep drawing
balls out of the bag until the bag only contains balls of a single
color (i.e you run out of a color) what is the probability you run out
of white balls first? (in terms of $r$ and $w$).

Supposedly the answer is just $r/(w+r)$, but I have no idea how this is arrived at. Any guidance?

Thanks

Best Answer

Think of the order you draw the balls out as a sequence, and consider the very last ball in that sequence - whichever colour it is will be the colour left in the bag when you reach the given stopping condition (i.e. if the last ball to be drawn would be white, then you must have drawn all the red balls already, and vice versa). Since we only care about what that last ball is, we can assign its colour first and then ignore the rest of the sequence, and that will be red with probability equal to $\frac{\# \mbox{ of red balls}}{\# \mbox{ of total balls}} = \frac{r}{w+r}$.