I came across the following problem and do not know how to tackle it.
Find the last two digits of $ 7^{81} ?$
Can someone point me in the right direction? Thanks in advance for your time.
I came across the following problem and do not know how to tackle it.
Find the last two digits of $ 7^{81} ?$
Can someone point me in the right direction? Thanks in advance for your time.
Last $2$ digits of powers of $7$:
$7^1 = 07$
$7^2 = 49$
$7^3 = 43$
$7^4 = 01$
..................................
$7^5 = 07$
$7^6 = 49$
$7^7 = 43$
$7^8 = 01$
So the last two digits repeat in cycles of $4$.
Hence $7^{81}$ has the last two digits same as that of $7^1$. So answer is : $07$
$7^2=49=50-1$
$\implies 7^4=(7^2)^2=(50-1)^2=50^2-2\cdot50\cdot1+1\equiv1\pmod {100}$
$$\implies 7^{81}=7\cdot(7^4)^{20}\equiv7\cdot1^{20}\pmod{100}\equiv7$$
In general, Euler's totient theorem or Carmichael's theorem can be used in such cases.
Here
$ \phi(100)=10\cdot\phi(10)=10\cdot\phi(2)\cdot\phi(5)=40$
$\implies 7^{40}\equiv1\pmod{100}$ as $(7,100)=1$
So, $7^{81}=(7^{40})^2\cdot7\equiv1^2\cdot7\pmod{100}\equiv7$
and $\lambda(100)=$lcm$(\lambda(25),\lambda(4))=$lcm$(20,2)=20$
So, $7^{81}=(7^{20})^4\cdot7\equiv1^4\cdot7\pmod{100}\equiv7$
$7^{81} = 283753509180010707824461062763116716606126555757084586223347181136007$. So, the last two digits are $07$. The first two digits are $28$. In fact, the last three digits are James Bond.
$\rm{\bf Hint}\ \ mod\,\ \color{#c00}2n\!: \ a\equiv b\, \Rightarrow\, mod\,\ \color{#c00}4n\!:\ \, a^2 \equiv b^2\ \ by \ \ a^2\! = (b\!+\!\color{#c00}2nk)^2\!=b^2\!+\!\color{#c00}4nk(b\!+\!nk)\equiv b^2$
$\rm So,\, \ mod\,\ \color{}50\!:\, 7^{\large 2}\!\equiv -1\Rightarrow mod\ \color{}100\!:\,\color{#0a0}{7^{\large 4} \equiv\, 1}\:\Rightarrow\:7^{\large 1+4n}\equiv\, 7\, \color{#0a0}{(7^{\large 4})}^{\large n} \equiv\, 7 \color{#0a0}{(1)}^{\large n} \equiv 7 $
We use the technique found in our answer to
$\quad$ last two digits of $14^{5532}$?
but now express it with more succinctness.
The integer $81$ has a binary representation of $1010001$.
We have the operator
$$ n \text{ mod 100} \mapsto n^2 \text{ mod 100}$$
and so we need to successively apply it at most $\text{len}(1010001) - 1$ (i.e. $6$ times) to the residue class $[7]$,
$$ [7] \mapsto [49] \mapsto [1]$$
Since we hit $[1]$ our work is done; the answer is
$$ (1 \cdot [1]) (\text{from } 2^6) \times (1 \cdot [1]) (\text{from } 2^4) \times (1 \cdot [7]) (\text{from } 2^0) = [7]$$