[Math] The Seven Dwarves (of Snow White fame)

combinatoricsprobability

The seven dwarves have seven beds in a dormitory room. One night, Sleepy is so tired that he falls asleep on the first bed that he sees. This has happened before, so the other dwarves follow a standard procedure as they enter the dormitory room later that night: if a dwarf can sleep in his own bed, he does so, but if not, he selects a random bed and uses that one. On the night in question, Grumpy is the fourth dwarf to enter the room to go to bed. What's the probability that he sleeps in his own bed?

Best Answer

Suppose that there are $n$ dwarfs, $D_1,\dots,D_n$, and they enter in reverse order (i.e., $D_n$ first and $D_1$ last). I claim that the probability that $D_k$ gets his own bed is $\frac{k}{k+1}$ for every $k<n$; in the present problem $k=4$, so the answer is $\frac45$.

When $D_k$ enters the room, there are $k$ beds still free. Since each dwarf except $D_n$ takes his own bed if it’s available, the beds belonging to $D_{k+1},\dots,D_{n-1}$ must all be occupied, and the free beds must be $k$ of the $k+1$ beds belonging to $D_1,\dots,D_k$, and $D_n$. When a dwarf picks a bed at random, the beds are in effect indistinguishable, so each of the $k+1$ beds belonging to these $k+1$ dwarfs is equally likely to be the one that’s already occupied. In particular, the probability that $D_k$’s bed is already occupied is $\frac1{k+1}$, so the probability that he gets his own bed is $\frac{k}{k+1}$.

Related Question