Skip to main content

2006 AIME I Problem 4

Problem 4 of 15EasierAlgebraNumber TheoryArithmetic

Let NN be the number of consecutive 00’s at the right end of the decimal representation of the product 1! 2! 3! 4!⋯99! 100!.1!\,2!\,3!\,4! \cdots 99!\,100!. Find the remainder when NN is divided by 1000.1000.

Your answer

Integer from 0 to 999
Show solution

Solution

Factors of 22 are plentiful, so NN is the exponent of 55 in the product. Each integer jj with 1≤j≤1001 \le j \le 100 appears as a factor in exactly 101−j101 - j of the factorials, namely j!,(j+1)!,…,100!.j!, (j+1)!, \ldots, 100!. Every multiple of 55 contributes one factor of 55 per appearance, and every multiple of 2525 contributes one more. Over j=5,10,…,100j = 5, 10, \ldots, 100 the appearances total 96+91+⋯+1=20⋅972=970,96 + 91 + \cdots + 1 = \frac{20 \cdot 97}{2} = 970, and over j=25,50,75,100j = 25, 50, 75, 100 they total 76+51+26+1=154.76 + 51 + 26 + 1 = 154. Hence N=970+154=1124,N = 970 + 154 = 1124, and the remainder upon division by 10001000 is 124.124.
AoPS wiki

Tagged: trailing zeros · factorial · summation

More practice