I recently had the following question, which I answered incorrectly, in a combinatorics exam:
How many ways are there to put 8 balls in 9 holes $H_1, ..., H_9$ if the balls are all different and only the holes $H_1, H_2, H_3, H_4$ are empty?
Apparently, the solution is:
Where $S(8,5)$ is the Stirling number. In effect, the solution is the number of surjective functions from the set of cardinality 8 to the set of cardinality 5.
Is someone able to explain this solution to me? From my understanding, if we know that $H_1, H_2, H_3, H_4$ are all empty, it's simply a matter of assigning 8 balls to the 4 holes. The question doesn't state anything about a hole containing at least one ball.