The number obtained from the last two nonzero digits of is equal to . What is ?
- A)
- B)
- C)
- D)
- E)
Answer
A
Key insight
Remove the 21 fives and 21 twos that make the zeros, then track only the remainder after dividing by 25. Runs of four non-multiples of 5 act like -1.
Solution
The idea: throw away the tens that make the zeros, then keep track of only a remainder, never the huge number itself.
Step 1: count the zeros. Each zero at the end comes from one paired with one . There are far more s than s, so count the s.
- Multiples of up to : of them.
- , , each give one extra : more.
That is fives, so ends in zeros. Let be with fives and twos taken out. The answer is the last two digits of .
Step 2: why we only need the remainder after dividing by 25. has twos in total (, counting multiples of ), so still has twos. That makes a multiple of . All five choices are multiples of , so that does not decide it. But the choices leave different remainders when divided by :
| Choice | |||||
|---|---|---|---|---|---|
| Remainder after dividing by |
So we find the remainder of after dividing by . Two rules help:
- To find the remainder of a product, you can multiply the remainders instead.
- A remainder of is "one short of ," so it behaves like : two of them multiply to a remainder of .
(Short notation: means and leave the same remainder when divided by .)
Step 3: a useful fact. Four numbers in a row with no multiple of multiply to a remainder of , that is :
- .
- .
In general, when you multiply out , you get plus terms that are all multiples of . (The terms with one factor add up to ; the others contain twice or more.)
Step 4: take the fives out of .
- The numbers from to that are not multiples of form groups of four: –, –, …, –. Their product acts like .
- The multiples of are . Taking out the fives leaves .
Step 5: do the same inside .
- Non-multiples of : the groups –, –, – give . The leftovers act like . Together: .
- Multiples of : . Taking out the fives leaves .
So with all fives removed leaves remainder , which is .
Step 6: take out the 21 twos. acts like , so acts like and acts like . We know leaves remainder , so leaves remainder . If leaves remainder (from to ), then is or . It must be even, so and .
Step 7: match. Only choice leaves remainder .
The answer is .
Why this works
The last two digits of a number are its remainder after dividing by , and . The factor is easy because so many s are left over, so all the work is with . Removing fives in layers (, then , then ) and treating each run of four as keeps every number small.
The trap
Forgetting that removing 21 fives also means removing 21 twos, or working with 90! itself, whose last two digits are just 00.
Concise solution
The exponent of in is , and the exponent of is . So ends in zeros and . This quotient still contains , so ; every choice is a multiple of , so the work is mod .
A useful fact. For any , (the other terms of the expansion are multiples of ).
Remove the 5s. Write , where is the product of the non-multiples of up to . Those form blocks of four, so . Similarly with . Since and , we get . Hence
Remove the 2s. , so . Then satisfies , so .
Among the choices, , , , ; only works.
The answer is .
Review in the AoPS books
- Introduction to Number Theory, Chapter 12: Introduction to Modular Arithmetic
- Introduction to Number Theory, Chapter 1: Integers: The Basics (§1.4, §1.5)
- Introduction to Number Theory, Chapter 10: Units Digits
- Introduction to Number Theory, Chapter 5: Divisor Problems (§5.2, §5.3)
Techniques
Use the answer choices (mod checks, size, form) to eliminate or select · Set up the equation/formula and compute; no special trick needed