This was a question on my combinatorics final.
Suppose $m$ people are sitting in a room with $n$ chairs. If everyone leaves and comes back, how many ways can they sit down such that no one gets their original chair?
If $m=n$, we simply get the derangement numbers. As another example, if person $A$ is in chair $1$, $B$ is in $2$, and no one is in $3$, then there are $3$ possible arrangements. Obviously $m\le n$ in general.
The question seems pretty simple, but I had a hard time getting a simple answer (I ended up with a pretty complicated recursion which I'm pretty sure was either wrong or not the best answer).
You are allowed to use derangement numbers, $d_i$, in the answer. Also a hint provided said that the answer would be a sum.
I'm looking for some thoughts on this. I guess I should add that the final is over; I'm asking out of curiosity since I probably won't get the exam back, at least for several weeks.