# Difference between revisions of "2017 UNM-PNM Statewide High School Mathematics Contest II Problems/Problem 1"

## Problem

What are the last two digits of $2017^{2017}$?

## Solution

In this problem, we will use the Chinese remainder theorem. This question is asking us to find $2017^{2017}\mod 100=17^{2017}\mod 100$. By the Chinese remainder theorem, we can find $17^{2017}\mod 25$ and $17^{2017}\mod 4$, and then "combine" them. $17^{2017}\mod4\equiv1^{2017}\mod4\equiv1\mod4$. To find $17^{2017}\mod4$, we'll look for a pattern. The pattern is $17, 14, 13, 21, 7, 19, 23, 16, 22, -1, -17, -14, -13, -21, -7, -19, -23, -16, -22, 1$. Since there are 20 terms, and $2017\equiv17\mod20$, we have that $17^{2017}\mod25\equiv2\mod25$. Now, we want to find a number that's $2\mod25$ and $1\mod4$. We find this number by clever guess and check. We know our number is odd, so it is $27\mod50$. First, we try $27$, but that doesn't work. Next, we try $77$, and that works! So, our answer is $\boxed{77}$