0

Find the number of words of length $8$ of distinct letters of the alphabet so that the words do not have both $A$ and $B$ in them.

I know the answer is $P(26,8) - (8)(7)(P(24,6))$, but I don't understand why completely. Why do I need to multiply the $7$ and the $8$?

N. F. Taussig
  • 76,571
NikNik
  • 115

1 Answers1

3

First count the number of words that contain both A and B. This number is $8 \times 7 \times ^{24} P_{6}$. That is because the letter $A$ can take any of the possible $8$ places in the word. The letter $B$ can then take any of the remaining $7$ places.

Therefore the answer is equal to total number of words of length eight minus the number of words of length eight that have both A and B: $$^{26}P_{8} -8\times 7 \times ^{24} P_{6}$$