Consider 9 boys and 15 girls. How many ways are there to arrange these 24 people on a line if all
boys stand next to each other and all girls stand next to each other?
(a)
${24 \choose 9}(9!)(15!)$
(b)
$2(9!)(15!)$
(c)
$(9!)(15!)$
(d)
$\frac{24!}{9!15!}$
Solution
First, we can either put the boys on the left side and girls on the right side or vice versa.
This doubles the number of ways: $2$
Then, we can arrange the boys in their section.
The first boy can be in any of the 9 spots in the boys section.
The second boy can be in any of the 8 remaining spots in the boys section.
We can continue this pattern until the last boy.
There are $9 \cdot 8 \cdot 7 \cdot 6 \cdot 5 \cdot 4 \cdot 3 \cdot 2 \cdot 1$ ways to arrange
We can rewrite this as $9! $
In the girls section, we can do the same thing.
The first girl can be in any of the 15 spots in the girls section.
The second girl can be in any of the 14 remaining spots in the girls section.
We can continue this pattern until the last girl.
There are $15 \cdot 14 \cdot 13 \cdot 12 \cdot 11 \cdot 10 \cdot 9 \cdot 8 \cdot 7 \cdot 6 \cdot 5 \cdot 4 \cdot 3 \cdot 2 \cdot 1$ ways to arrange
We can rewrite this as $15! $
Thus, the total number of ways is $2 \cdot 9! \cdot 15! $