AMC 10 Step by Step

2005 AMC 10A Problem 14

P11-15~3 minPrint

How many three-digit numbers satisfy the property that the middle digit is the average of the first and the last digits?

Log in to save your progress.
Show solution without answering

Key insight

The middle digit is decided by the other two, and it is a whole number only when the first and last digits are both odd or both even.

Solution

Call the digits aa, bb, cc, so the number is abcabc and aa cannot be 00. The middle digit must be the average of the other two:
b=a+c2.b = \frac{a + c}{2}.

  1. The middle digit is not a free choice. Once aa and cc are picked, bb is fixed. So we only need to count good pairs (a,c)(a, c).
  2. When is the average a whole number? When a+ca + c is even. That happens when aa and cc are both odd or both even. For example, 33 and 77 average to 55, but 33 and 66 average to 4.54.5, which is not a digit.
  3. Is bb always a real digit? Yes. The average of two digits is between 00 and 99, so it is never too big.
  4. Count, both odd. aa can be 1,3,5,7,91, 3, 5, 7, 9 (55 choices) and cc can be 1,3,5,7,91, 3, 5, 7, 9 (55 choices): 5×5=255 \times 5 = 25 pairs.
  5. Count, both even. aa can be 2,4,6,82, 4, 6, 8 (44 choices, since aa cannot be 00) and cc can be 0,2,4,6,80, 2, 4, 6, 8 (55 choices): 4×5=204 \times 5 = 20 pairs.
  6. Total. 25+20=4525 + 20 = 45.

The answer is (E) 45\boxed{\textbf{(E)}\ 45}.

Why this works

"The average is a whole number" is really a question about odd and even: two whole numbers have a whole-number average exactly when they are both odd or both even. Noticing that the middle digit is decided for you turns a three-digit search into a quick count of pairs. A shortcut: for each of the 99 first digits, exactly 55 of the 1010 last digits match it, giving 9×5=459 \times 5 = 45.

Alternative approach

Go through the middle digit. For each bb, count pairs (a,c)(a, c) with a+c=2ba + c = 2b and a≥1a \ge 1:

bb123456789
pairs246897531

For example, b=1b = 1 allows a+c=2a + c = 2, which is 1+11{+}1 or 2+02{+}0. The row adds up to 4545.

Concise solution

A shorter write-up, the way contest solutions are usually written. It may take a different route from the solution above.

Call the digits aa, bb, cc with a≠0a \neq 0. The condition b=a+c2b = \frac{a+c}{2} has two consequences: a+ca + c must be even, and once aa and cc are chosen, bb is fixed. Since aa and cc are digits, b=a+c2b = \frac{a+c}{2} is automatically between 00 and 99, so it is always a legal digit.

So we just count pairs (a,c)(a, c) with a+ca + c even, i.e. with aa and cc of the same parity.

  • aa odd (55 choices: 1,3,5,7,91,3,5,7,9), cc odd (55 choices): 2525 pairs.
  • aa even (44 choices: 2,4,6,82,4,6,8), cc even (55 choices: 0,2,4,6,80,2,4,6,8): 2020 pairs.

Total 25+20=4525 + 20 = 45.

The answer is (E) 45\boxed{\textbf{(E)}\ 45}.

Review in the AoPS books

Similar problems

Problem © Mathematical Association of America (MAA), American Mathematics Competitions. Reproduced for non-commercial educational use. Solution and commentary are original to this site.