Solution:
Concept:
- Permutation (arrangement, order matters): the number of ways of arranging r objects chosen from n different objects in a row is nPr=(n−r)!n!.
- Multiplication principle: if one job can be done in m ways and after it a second job in n ways, both jobs together can be done in m×n ways.
- Addition principle: when the cases are separate (no choice belongs to two cases), the total number of ways is the sum of the numbers for the cases.
- Restriction first: seat the people who have a condition first, then arrange everyone else in the seats that are left.
(i)
Step 1 — X and Y on the window side.
- Seat X and Y in 2 of the 4 window seats, in order: 4P2=12 ways.
- The other 5 people fill the 5 remaining seats in 5!=120 ways.
12×120=1440
Step 2 — X and Y on the other side.
Seat them in 2 of the 3 seats: 3P2=6 ways; the others in 5! ways.
6×120=720
Step 3 — Add.
The two cases are separate.
Total=1440+720=2160
So (i) gives 2160 ways.
(ii)
Step 1 — X at the window, Y opposite.
X has 4 seats and Y has 3 seats; the other 5 people sit in 5! ways.
4×3×120=1440
Step 2 — Y at the window, X opposite.
In the same way this case also gives 1440 ways.
Step 3 — Add.
Add the two separate cases.
Total=1440+1440=2880
So (ii) gives 2880 ways.
(iii)
Step 1 — Seat X, Y and Z.
Seat them in 3 of the 4 window seats, in order.
4P3=4×3×2=24
Step 2 — Seat the rest.
The other 4 people fill the remaining 4 seats in 4!=24 ways.
Total=24×24=576
So (iii) gives 576 ways.
Check: (i) and (ii) together cover every seating, so their sum must be 7!.
2160+28807!=5040=5040
Therefore, (i) 2160; (ii) 2880; (iii) 576.