Finding the last two digits of $5312^{442}$

As $5312\equiv12\pmod{100},5312^{442}\equiv12^{442}\pmod{100}$

Now as $(12,100)=4$ let us find $12^{442-1}\pmod{100/4}$

As $(12,25)=1,$ by Euler Theorem, $$12^{20}\equiv1\pmod{25}$$

As $441\equiv1\pmod{20},12^{441}\equiv12^1\pmod{25}$

$$\implies12\cdot12^{441}\equiv12\cdot12^1\pmod{12\cdot25}$$ $$\equiv144\pmod{300}\equiv144\pmod{100}\equiv44\pmod{100}$$


[quote] To start, you can immediately reduce 5312 modulo 100 so that you're solving $12^{442}$ instead.

Then, you solve this (mod 4) and (mod 25)

  • (mod 4), it is pretty clear what the result would be

  • (mod 25), you can use Euler's Theorem.

Then, combine the results back to (mod 100).