I'm preparing myself for discrete math exam and here's one of the preparation problems:
Evaluate $$7^{8^9}\mod 100$$
Here's my solution: $7^2\equiv49 \mod 100\implies (7^2)^2\equiv49^2=2401\equiv 1\mod 100$
So, as it turns out $7^4\equiv 1\mod 100$. It will be useful later. Now let's examine $8^9\mod 100$.
We have $512=8^3\equiv 12 \mod 100$, so $(8^3)^3\equiv 12^3 = 1728 \equiv 28 \mod 100$. So, as $8^9\equiv 28 \mod 100$, then $8^9=100x+28$ for some natural $x$. So:
$7^{8^9}=7^{100x+28}=7^{100x}7^{28}=(7^4)^{25x}(7^4)^7\equiv 1^{25x}1^7 \equiv 1 \mod 100$
Which means the final answer is that $7^{8^9}\mod 100=1$.
That's my solution, but I'm curious about other ones. Has anybody have any ideas?
$7^2\equiv -1\mod 50$, hence $7^4\equiv 1\mod 100$.
Thus $\,7^{8^9}=\bigl(7^8\bigr)^{8^8}=\bigl((7^4)^2\bigr)^{8^8}\equiv 1\mod 100$.