AMC 10 · 2015 · #23

Grade 6 arithmetic
legendre-formulafactorialfloor-function casework ↑ Prerequisites: factoriallegendre-formula
📏 Long solution 💡 4 insights
Problem
A factorial like n! ends in a string of zeros. Call the number of trailing zeros of n! by the name k. We need every whole number n > 4 for which (2n)! ends in exactly 3k zeros — three times as many as n!. Take the four smallest such n, add them to get s, and report the sum of the digits of s.

Pick an answer.

(A)
7
(B)
8
(C)
9
(D)
10
(E)
11

AMC 10 2015 problem © Mathematical Association of America (MAA AMC). Reproduced for educational use.

How to solve
Strategy Guess and Check

There is no neat formula spitting out the answer, but each candidate n is easy to test once we know how to count trailing zeros, so tool #6 (Guess and Check) drives the search: try n=5,6,7,… in order and keep the ones that work. Before testing, tool #16 (Change Focus) makes each test cheap — instead of chasing factors of 10, we count only factors of 5, since fives are rarer than twos and so decide the number of zeros. Tool #2 (Make a Systematic List) keeps the trials organized in a small table of n, k, and the zeros of (2n)!, so the four winners stand out without missing any.

1STEP 1

Count only the fives

A zero needs a paired 2 and 5, and 5's run out before 2's, so a factorial's zero-count is exactly how many 5's it holds.

trailing zeros of m! = (number of factors of 5 in m!)
2STEP 2

A way to count the fives

Count factors of 5 in m! by adding the multiples of 5 up to m, then the multiples of 25, and so on.

#5's in m! = ⌊ m/5⌋ + ⌊ m/25⌋ + …
3STEP 3

Write the requirement

Write Z(m) for the zero-count of m!; then the test on each n is simply whether Z(2n) equals three times Z(n).

Z(2n)=3 Z(n)
4STEP 4

Test n from 5 to 9

n=5,6,7 give only 2 zeros in (2n)! (need 3), but n=8 and n=9 hit Z(16)=Z(18)=3, so 8 and 9 are the first two winners.

Z(8)=1, Z(16)=3; Z(9)=1, Z(18)=3
5STEP 5

Test n from 10 to 14

n=10,11,12 reach only 4 zeros (need 6), but at 2n=26,28 the number 25 adds a bonus 5, so Z(26)=Z(28)=6 and 13,14 are the next winners.

Z(13)=2, Z(26)=6; Z(14)=2, Z(28)=6
6STEP 6

Add and take the digit sum

The four winners 8,9,13,14 add to s=44, and its digits give 4+4=8.

s=8+9+13+14=44; 4+4=8
Answer
8
The winners come in two pairs, {8,9} and {13,14}, each sitting just after a jump in the five-count of (2n)! — at 16,18 and at 26,28 — which fits why they suddenly satisfy Z(2n)=3Z(n). The skipped values 10,11,12 correctly fail because doubling them only reaches 4 zeros while 6 are required. Summing 8+9+13+14=44 and the digit sum 8 all use small, checkable arithmetic, and 8 is one of the listed choices.
💡Key takeaway

Trailing zeros come only from factors of 5, so count the fives, then just try n in order and keep the ones where (2n)! has three times as many.

  • Count only the fives
  • A way to count the fives
  • Write the requirement
  • Test n from 5 to 9
  • Test n from 10 to 14
  • Add and take the digit sum