2

The way I usually do is to observe the last digit of $3^1$, $3^2$,... and find the loop. Then we divide $1006$ by the loop and see what's the remainder. Is it the best way to solve this question? What if the base number is large? Like $33^{1006}$? Though we can break $33$ into $3 \times 11$, the exponent of $11$ is still hard to calculate.

yashirq
  • 505

6 Answers6

4

You have $$3^2=9\equiv -1\pmod{10}.$$

And $1006=503\times 2$, so

$$3^{1006}=(3^2)^{503}\equiv (-1)^{503}\equiv -1\equiv 9\pmod{10}.$$

So the last digit is $9$.


And for something like $11$, you can use the fact that $11\equiv 1\pmod {10}.$

E. Joseph
  • 14,843
2

$3^{1006}$ or $33^{1006}$

doesn't really matter

$33\equiv 3\pmod {10}\\ 33^{1006}\equiv 3^{1006}\pmod {10}$

$3^4 = 81$

You might say this as $3^4\equiv 1 \pmod{10}$

The last digit of $3^n$ is the same last digit as $3^{n+4k}$ that is:

$(3^{n+4k}) = (3^n)(3^{4k})\equiv (3^n)(1) \pmod{10}$

$1006 = 251\cdot 4 + 2$

the last digit of $3^{1006}$ is the same as the last digit of $3^2$

Doug M
  • 57,877
2

You have

\begin{cases}3^1& =3\\ 3^2& =9 \\ 3^3&=27\\3^4&= 81\\3^5&= 243\end{cases} Thus the last digit repeats after $4$ steps. Since $1006=251\cdot 4+2$ it is

$$3^{1006}=(3^4)^{251}\cdot 3^2.$$ The last digit of $(3^4)^{251}$ is $1$ and the last digit of $3^2=9.$ So the answer you are looking for is $9.$

To compute the last digit of $33^{1006}$ you are in the right way. Since $33=3\cdot 11$ and the last digit of $11^n$ is $1$ you have that the last digit of $33^{1006}$ is the same of $3^{1006}.$

mfl
  • 29,399
1

HINT:

Find the last digit of $3^{1006\bmod4}$.


Adding a formal solution, just in case anyone will find it useful:

You are looking for $3^{1006}\pmod{10}$.

Since $\gcd(3,10)=1$, by Euler's theorem, $3^{\phi(10)}\equiv1\pmod{10}$.

We know that $\phi(10)=\phi(2\cdot5)=(2-1)\cdot(5-1)=4$.

Therefore $3^{4}\equiv1\pmod{10}$.

Therefore $3^{1006}\equiv3^{4\cdot251+2}\equiv(\color\red{3^4})^{251}\cdot3^2\equiv\color\red{1}^{251}\cdot3^2\equiv1\cdot9\equiv9\pmod{10}$.

barak manos
  • 43,109
0

The powers of $3$ cycle from $1\to3\to9\to7$, depending upon the exponent's modulus with respect to $4$. Since $1006\equiv 2\pmod{4}$, the last digit of $3^{1006}$ is $9$.

You can still use this tactic for larger bases. Suppose we want the last digit of $33^{1006}$, as you suggest. Since $33=30+3$, the powers of $33$'s last digit are completely determined by the powers of $3$.

Laars Helenius
  • 7,965
  • 1
  • 23
  • 35
0

Very soon you will learn Euler's theorem:

If the greatest common factor of $a$ and $n$ then $a^{\phi{n}} \equiv 1 \mod n$ where $\phi(n)$ is the number of numbers relatively prime to $n$ that are less than $n$.

As $1,3,7$ and $9$ are relatively prime to $10$, and $\gcd(3,10) = 1$ we know $\phi(10) = 4$ and $3^4 \equiv 1 \mod 10$ so $3^{1006} = 3^{4*251 + 2} \equiv 3^2 \equiv 9 \mod 10$.

As $33 = 3*10 + 3$ $33^n = (30 + 3)^n = 10*something + 3^n$ will have the same last digit. But $\gcd(33,10) = 1$ so $3^4 \equiv 1 \mod 10$. And everything is the same.

What would be harder is the last two digits of $33^{1006}$. $\gcd(33,100) =1$ so $33^{\phi(100)} \equiv 1 \mod 100$. But what is $\phi(100)$?

There is a thereom that $\phi(p) = p-1$ and that $\phi(p^k) = p^{k-1}(p-1)$ and then $\phi(mn) = \phi(m)\phi(n)$ so $\phi(100)=\phi(2^2)\phi(5^2) = 2*1*5*4 = 40$. So there are $40$ numbers less than $100$ relatively prime to $100$.

and $33^{40} \equiv 1 \mod 100$ so $33^{1006 = 40*25 +6} \equiv 33^6 \mod 100 \equiv 30^2 + 2*3*30 + 3^2 \equiv 189 \equiv 89 \mod 100$. The last two digits are $89$.

See:

https://en.wikipedia.org/wiki/Modular_arithmetic

https://en.wikipedia.org/wiki/Euler%27s_theorem

https://en.wikipedia.org/wiki/Euler%27s_totient_function

fleablood
  • 124,253