Maths WorkshopMaths problems with full solutions
Exercise 991Combinatorics › Inclusion-exclusionL1Added 3 Nov 2026

Derangements of $5$ elements

#derangements#$D_5$#computation

Statement

Compute D5D_5, the number of derangements of 55 elements.

Hint

D5=5!∑k=05(−1)kk!D_5=5!\sum_{k=0}^5\frac{(-1)^k}{k!}.

Show solutionHide solution

Solution

Compute. D5=120(1−1+1/2−1/6+1/24−1/120)=120(1/2−1/6+1/24−1/120)D_5=120(1-1+1/2-1/6+1/24-1/120)=120(1/2-1/6+1/24-1/120).

12−16+124−1120=60−20+5−1120=44120\frac12-\frac16+\frac1{24}-\frac1{120}=\frac{60-20+5-1}{120}=\frac{44}{120}.

So D5=120⋅44/120=44D_5=120\cdot44/120=44.

Conclusion. D5=44D_5=44.