Vanessa plans to arrange A, B, C, D, E, F, G, and H in a row on the wall. Find
the number of permutations for each of the following.
1. A and B must be placed next to each other.
Case I: A is immediately left of B
Then she has only 7 things to arrange: AB, C, D, E, F, G, H
That's 7! ways.
Case II: A is immediately right of B
Then she has only 7 things to arrange: BA, C, D, E, F, G, H
That's also 7! ways.
Answer: 7!+7! = 2*7! = 2*5040 = 10080
-----------------------------------------
2. A and B must not be placed next to each other.
We calculate the number of ways the 8 things can be arranged without
restriction, and then subtract the result of problem 1:
8!-2*7! = 40320-10080 = 30240
------------------------------------------------------------
3. A, B, and C must be placed next to each other, and at the same time,
E,F and G must also be placed next to each other.
A,B, and C can be placed together in 3! or 6 ways.
E,F, and G can be placed together in 3! or 6 ways.
That's 6*6 or 36 ways to group A,B,C and E,F,G
For each of those 36 ways to arrange those two triplets, there are 4 things to
arrange, {A,B,C}, (E,F,G}, D, and H. That's 4!=24 ways.
Answer 6*6*24 = 864 ways.
Edwin