Learn / Library / Combinatorics
Keeping people apart
distinct people sit in a row of chairs. specific people must not sit next to each other. How many seating orders are possible?
Checking an answer needs JavaScript. The hint and the solution open without it.
Hint
Subtract the bad seatings from all seatings.
Solution
- Without any restriction there are seatings.
- To count the bad seatings, glue the specific people into one block, which leaves units.
- The units can be ordered in ways and the pair can swap in ways, so there are bad seatings.
- Subtracting gives .
- Hence the number of valid seatings is .
Answer: