2

Question 1: What are the last two digits of $17^{198}$?

My Attempt: The pdf hinted to reduce it via mod $100$. So my work is as follows:

Since $17^2\equiv289\equiv-11\mod100$, we have$$17^{198}\equiv (-11)^{99}\equiv-11^{99}\mod100$$ However, I'm not sure how to compute $-11^{99}$ without too much of a hassle.

Questions:

  1. How do you complete this problem?
  2. Why use mod $100$? Why not mod $50$ or some other number?
Crescendo
  • 4,417

6 Answers6

3

An alternative approach, exploiting the Chinese remainder theorem and the fact that $2$ is a generator in $\mathbb{Z}/(25\mathbb{Z})^*$:

$$ 17^{198}\equiv (-8)^{198} \equiv 2^{3\cdot 198} \equiv 2^{14} \equiv 16\cdot 1024\equiv -16\equiv 9\pmod{25} $$ $$ 17^{198}\equiv 1\pmod{4} $$ together imply $17^{198}\equiv \color{red}{9}\pmod{100}$.

Jack D'Aurizio
  • 361,689
2

Note $\, 17^{\large 2}\!= -1\!+\!10k\,\Rightarrow\, \color{#c00}{17^{\large 20}}\equiv \overbrace{(-1\!+\!10k)^{\large 10}\!\equiv (-1)^{\large 10}}^{\large\rm Binomial\ Theorem}\!\!\equiv \color{#c00}{\bf 1}\pmod{\!100}$

thus we conclude $\ 17^{\large 198}\equiv\dfrac{(\color{#c00}{17^{\large 20}})^{\large 10}}{17^{\large 2}}\equiv\dfrac{\color{#c00}{\bf 1}}{-11}\equiv \dfrac{9}{-99}\equiv 9\pmod{\!100}$

Bill Dubuque
  • 282,220
2

Reducing an integer mod. $100$ consists exactly in taking its last two digits !

Indeed, if we consider $n\in\mathbb{N}$ and divide it by $100$, we get something like $n=100q+r$ with $0\le r<100$.

Now, for your example, you mean mod. 100 and not mod. 10 ...

$$17^{198}\equiv-11^{99}\,\,(mod.\,100)$$

But $11^{99}=(11^3)^{33}=(1331)^{33}\equiv31^{33}=(31^3)^{11}=29791^{11}\equiv91^{11}$

and $91^2=8281$, so $91^2\equiv81$. Then $91^{10}=(91^2)^5\equiv81^5=3486784401\equiv1$

Finally $11^{99}\equiv91\,\,(mod.\,100)$ and so $$\boxed{17^{198}\equiv9\,\,(mod.\,100)}$$

Adren
  • 8,184
1

Hint: First note that $-11 \equiv -1 \pmod {10}$. There's only two possible integer powers of $-1$.

For your second question, we use $\pmod{100}$ because the last two digits of any integer is exactly the remainder when divided by $100$.

Yiyuan Lee
  • 14,595
  • So does that mean that mod $1000$ gives you the last three digits, mod $10000$ gives you the last four digits, and so on? – Crescendo Jan 27 '17 at 15:06
  • @Crescendo yepper – The Count Jan 27 '17 at 15:09
  • Okay, cool. And also, what about a number of the form $a^{b^c}\mod n$? How would you reduce? Is it the same as $a^b$ where you reduce $a$ and then simplify? Or is there a quicker way? – Crescendo Jan 27 '17 at 15:18
1

For the first question, you may want to refer to this Wikipedia page where you are presented with some different methods. My favorite one and the most pratical is under the title "Right-to-left binary method".

As for the second question, what is the remainder of $56$ when divided by $100$? And what about $543$? And $642058311$? Note that $56 = 0\cdot100 + 56, 543 = 5\cdot100 + 43, 642058311 = 6420583\cdot100 + 11$. If you take those equalities $\mod 100$, everything but the last two digits of each number is reduced to $0$.

RGS
  • 9,883
-1

Let $G=(\mathbb{Z}/100\mathbb{Z})^{*}$. Since $|G|$=40 and $17\in G$, we have $$ 17^{198} = 17^{40\cdot 5}\cdot 17^{-2}=1\cdot 17^{-2} \ mod\ 100$$ To find $17^{-2}\ mod\ 100$ we note first that $17\cdot 3 = 1 \ mod \ 10$. Then, we only have to solve $$ 17\cdot (10x+3) = 1 \ mod\ 100$$ for $x\in[0,9]\cap\mathbb{Z}$, in order to find the inverse. Doing some computations, we find $$ 70x=50 \ mod\ 100 $$ $x=5$ solves the equation and one can verify directly that $17\cdot 53=1 \ mod\ 100$. We deduce $17^{198}=53^2 = 9\ mod\ 100$

  • Generally Hensel lifting can be done very simply for inverses, e.g. here

    $$\begin{align} \bmod{10}!:\ \ ,&\ \color{#0a0}{17}^{-1}\equiv \color{#c00}3\[.4em] {\rm i.e.}\ \ \ \ &\ \color{#0a0}{17}\cdot\color{#c00}3\equiv\color{darkorange} 1!+!5\cdot 10\[.4em] \Rightarrow\ \bmod{10^2}!:\ &,\dfrac{1}{\color{#0a0}{17}}\overset{\times\ \color{#c00}3_{\phantom{|}}!}\equiv \dfrac{3}{\color{darkorange}1+5\cdot 10}\equiv 3(1-5\cdot 10)\equiv 53\end{align}\qquad\qquad$$

    – Bill Dubuque Oct 23 '24 at 17:58