4 ms·
Another interesting way to formulate it is as a differential equation in the number of empty buckets as a function of time. Given k empty buckets, the probabil
by SamReidHughes 6y ago
Another interesting way to formulate it is as a differential equation in the number of empty buckets as a function of time. Given k empty buckets, the probability of picking an empty bucket is k/n. For large values of n and k, we can pretend it's a continuous and not-particularly-stochastic differential equation dk/dt = -k/n, with k(0) = n.
That's classic exponential decay, the solution being k = ne^(-t/n). Thus k(n) = ne^(-1).