Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

In how many ways can $m$ people entering a theatre be seated in two rows, each containing $n$ seats with the condition that no two sit in adjacent seats in the first row?

share|cite|improve this question
up vote 2 down vote accepted

First calculate how many ways $j$ seats can be occupied from $n$: this is ${n \choose j}$ if $n\ge j$.

Then calculate how many ways $k$ seats can be occupied from $n$ with none adjacent: this is ${n+1-k \choose k}$ if $n+1 \ge 2k$

So the answer to the original question is $$\sum_{k= \max(0,m-n)}^{\min \left(m ,\lfloor(n+1)/2\rfloor \right)} {n+1-k \choose k}{n \choose m-k} $$ if $2m \ge 3n+1$, and $0$ otherwise.

Multiply by $m!$ if order of the individuals matters.

share|cite|improve this answer

First figure out how many ways there are to choose which seats are sat in in the first place. The answers to your earlier question describe useful ways of looking at that subproblem.

Then figure out, given any decision about which $m$ seats to use, how many ways there are to distribute the $m$ people among them. That is a standard problem.

Finally multiply the two subresults.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.