4

This is a exam question, something related to network security, I have no clue how to solve this!

Last two digits of $7^4$ and $3^{20}$ is $01$, what is the last two digits of $14^{5532}$?

Martin Sleziak
  • 51,859
  • 20
  • 181
  • 357
karthikeayan
  • 169
  • 7

6 Answers6

5

By the Chinese remainder theorem, it is enough to find the values of $14^{5532}\mod 4$ and $\bmod25$.

Now, clearly $\;14^{5532}\equiv 0\mod 4$.

By Euler's theorem, as $\varphi(25)=20$, and $14$ is prime to$25$, we have: $$14^{5532}=14^{5532\bmod20}=14^{12}\mod25.$$ Note that $14^2=196\equiv -4\mod25$, so $14^{12}\equiv 2^{12}=1024\cdot 4\equiv -4\mod25$.

Now use the C.R.T.: since $25-6\cdot4=1$, the solutions to $\;\begin{cases}x\equiv 0\mod 4\\x\equiv -4\mod 25\end{cases}\;$ are: $$x\equiv \color{red}0\cdot25-6\cdot{\color{red}-\color{red}4}\cdot 4= 96\mod 100$$ Thus the remainder last two digits of $14^{5532}$ are $\;96$.

Bernard
  • 173,269
  • 10
  • 66
  • 166
  • CRT is overkill since $\, -4\equiv 0\pmod 4\, $ so $\ x\equiv -4\pmod{100}\ $ is a solution. We can simplify even further noting $\,14\,$ is a square mod $\,25,\,$ see my answer. – Bill Dubuque Dec 15 '16 at 02:12
  • @Bill Dubuque: Yes, but I think the question the *general* way to solve. Your comment is useful to show students they can, and certainly should, think before applying any general solution. – Bernard Dec 17 '16 at 00:08
  • OP makes no mention of that. In fact the OP says it's an exam question, so speed is important, so widely applicable optimizations such as this [CRT constant case optimization](http://math.stackexchange.com/a/2006919/242) are surely of interest; i.e. above $\,x\equiv \color{#c00}{-4}\pmod{\!4\ \&\ 25}\iff x\equiv \color{#c00}{-4}\pmod{4\cdot 25}.\,$ Ditto for the complete elimination of CRT as in my answer. But of course I do agree that one should know both the general / mechanical results as well as the special cases / optimizations, shortcuts, and detours. – Bill Dubuque Dec 17 '16 at 00:26
4

Finding the last two digits necessarily implies $\pmod{100}$

As $(14^n,100)=4$ for $n\ge2$

Let use start with $14^{5532-2}\pmod{100/4}$ i.e., $14^{5530}\pmod{25}$

As $14^2\equiv-2^2\pmod{25}$

Now $2^5\equiv7,2^{10}\equiv7^2\equiv-1\pmod{25}$

$\implies14^{10}=(14^2)^5\equiv(-2^2)^5=-2^{10}\equiv-1(-1)\equiv1$

As $5530\equiv0\pmod{10},14^{5530}\equiv14^0\pmod{25}\equiv1$

Now use $a\equiv b\pmod m\implies a\cdot c\equiv b\cdot c\pmod {m\cdot c} $

$\displaystyle14^{5530}\cdot14^2\equiv1\cdot14^2\pmod{25\cdot14^2}$

As $100|25\cdot14^2,$

$\displaystyle14^{5530+2}\equiv14^2\pmod{100}\equiv?$

lab bhattacharjee
  • 1
  • 18
  • 201
  • 317
3

${\rm mod}\,\ \color{#c00}{25}\!:\, \ 14\equiv 8^{\large 2}\Rightarrow\, 14^{\large 10}\equiv \overbrace{8^{\large 20}\equiv 1}^{\rm\large Euler\ \phi}\,\Rightarrow\, \color{#0a0}{14^{\large 1530}}\equiv\color{#c00}{\bf 1}$

${\rm mod}\ 100\!:\,\ 14^{\large 2}\, \color{#0a0}{14^{\large 1530}} \equiv 14^{\large 2} (\color{#c00}{{\bf 1}\!+\!25k}) \equiv 14^{\large 2} \equiv\, 96$

Bill Dubuque
  • 265,059
  • 37
  • 279
  • 908
  • The prior line essentially uses a generalization of the *mod distributive law* below $$\large ca\,\bmod\, cn\, =\, c\,(a\bmod n)$$ See [this answer](http://math.stackexchange.com/a/2059937/242) for more on this viewpoint. To be clear, you don't need to know about this to understand the above answer. It's merely a tangential remark for enrichment. – Bill Dubuque Dec 17 '16 at 01:02
1

The OP quickly realizes that we can't write $14^k \equiv 1 \pmod{100}$ with $k \gt 0$, but there are still relations to be found in (multiplicative) semigroups.

If the last digit of integers $a$ and $b$ end in $6$, then the last digit of the product ends in $6$. This motivates us to write

$\quad 14^2 \equiv 96 \equiv -4 \pmod{100}$

and

$\quad 96^2 \equiv 16 \pmod{100}$
$\quad 96^3 \equiv 36 \pmod{100}$
$\quad 96^4 \equiv 56 \pmod{100}$
$\quad 96^5 \equiv 76 \pmod{100}$
$\quad 96^6 \equiv 96 \pmod{100}$

and

$\quad 96^{36} \equiv 96 \pmod{100}$
$\quad 96^{216} \equiv 96 \pmod{100}$
$\quad 96^{1296} \equiv 96 \pmod{100}$

So

$\; 14^{5532} = (14^2)^{2766} \equiv 96^{2766} \equiv (96^{1296})^2 (96^{174}) \equiv 96^{176} \equiv (96^{36})^4 (96^{32}) \equiv 96^{36} \equiv 96 \pmod{100}$

CopyPasteIt
  • 11,076
  • 1
  • 20
  • 43
0

Consider the following class of exam questions:

If $n$ is even find the last two digits of $n^k$.

There is a quick way of cranking out the answers by giving the multiplicative semigroup,

enter image description here

contained in $\mathbb {Z} / \text{100} \mathbb {Z}$, a central/absorbing role.

We know that $76 \times 76 \equiv 76 \pmod{100}$ and more generally that for any $a$ in the semigroup

$\quad 76 \times a \equiv a \pmod{100}$

(we actually have a group with the identity being $76$)

We know that there is an easy calculation algorithm that can be used to multiply any two of these residue numbers.

Example: For $56 \times 96 \pmod{100}$ the tens digit is equal to the residue $5 + 9 + 3 \pmod{10}$:

$\quad 56 \times 96 \equiv 76 \pmod{100}$

We know that given an even integer $n$ such that $n \not\equiv 0 \pmod{10}$, at least one of the residue classes

$\quad [n], [n^2], [n^4] \quad \pmod{100}$

belongs to our semigroup.

We know that given an even integer $n$ such that $n \not\equiv 0 \pmod{10}$,

$\quad n^{20} = 76 \pmod{100}$

Now with these preliminaries we can mentally turn the crank (recall that $14^2 = 196$) ,

$\; 14^{5532} \equiv 76 \times 14^{12} \equiv 76 \times (14^2)^6 \equiv 76 \times (96)^2 \times (96)^2 \times (96)^2 \equiv$
$\quad \quad \quad \quad 76 \times 16 \times 16 \times 16 \equiv 96 \pmod{100}$

CopyPasteIt
  • 11,076
  • 1
  • 20
  • 43
0

The following calculations can be easily done by hand on scrap paper, but we organized this preparatory work on a google sheet.

The outputs from these formulas

enter image description here

are

enter image description here

With this done we can mentally write out

$\quad 14^{5532} \equiv (16) (56) (36) (56) (36) (16) (36) \equiv$

$\quad\quad\quad\quad (56) (56) (36) (56) (36) (36) \equiv$

$\quad\quad\quad\quad (36) (36) (56) (36) (36) \equiv$

$\quad\quad\quad\quad (96) (56) (96) \equiv$

$\quad\quad\quad\quad (16) (56) \text{ mod 100} $

Since $(10 + 6)(50 + 6) = 500 + 60 + 300 + 36$, we can write

$\quad 14^{5532} \equiv 96 \text{ mod 100} $

CopyPasteIt
  • 11,076
  • 1
  • 20
  • 43