How many six-letter words formed from the letters of AMC do not contain the substring AMC? (For example, AMAMMC has this property, but AAMCCC does not.)
Problem 1264
Official solution
1. Total Number of Six-Letter Words:
The total number of six-letter words that can be formed using the letters A, M, and C (with repetition allowed) is given by:
2. Counting Words Containing the Substring "AMC":
We use complementary counting to find the number of words that do not contain the substring "AMC". First, we count the number of words that do contain the substring "AMC".
- Placement of "AMC":
The substring "AMC" can appear in the six-letter word in the following positions:
- Starting at position 1: AMCxxx
- Starting at position 2: xAMCxx
- Starting at position 3: xxAMCx
- Starting at position 4: xxxAMC
Thus, there are 4 possible positions for the substring "AMC".
- Remaining Letters:
After placing "AMC" in one of the positions, we have 3 remaining positions to fill with any of the letters A, M, or C. The number of ways to fill these 3 positions is:
- Total Count of Words Containing "AMC":
Therefore, the total number of six-letter words containing the substring "AMC" is:
3. Subtracting Overcounted Cases:
We need to subtract the cases where "AMC" appears more than once, as they have been counted multiple times. Specifically, the word "AMCAMC" has been counted twice in the above calculation.
- Count of "AMCAMC":
There is exactly 1 such word: "AMCAMC".
- Adjusting the Count:
Therefore, we subtract 1 from our previous count:
4. Complementary Counting:
Finally, we subtract the number of words containing "AMC" from the total number of six-letter words to find the number of words that do not contain the substring "AMC":
Conclusion: