Maths Olympiad Prep

Library / /278 of 348

Combinatorics Difficulty 5.1 AIME, harder Find the answer

Call a string of letters SS an almost palindrome if SS and the reverse of SS differ in exactly two places. Find the number of ways to order the letters in HMMTTHEMETEAMH M M T T H E M E T E A M to get an almost palindrome.

A number or a short expression. Fractions can be typed as 3/2, and spacing doesn't matter.

Solution

Note that T,E,AT, E, A are used an odd number of times. Therefore, one must go in the middle spot and the other pair must match up. There are are 32(6!2!)=21603 \cdot 2\left(\frac{6!}{2!}\right)=2160 ways to fill in the first six spots with the letters T,H,E,M,MT, H, E, M, M and a pair of different letters. The factor of 3 accounts for which letter goes in the middle.

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: Omni-MATH, licensed Apache-2.0. Statement and solution reproduced as published; topic and difficulty added by this site.