4

Find the last digit of $$7^{802} -3^{683}$$

$$7^{802} -3^{683}=(50 -1)^{401} -3(10 -1)^{341}$$ $$=50k -1 -3(10m -1) \space \text{where k,m are fixed integer } $$ $$=50k -30m +2 $$ So,the last digit will be $2$

Someone just added this question, but deleted it. I solved this question and got this thing. I just want to know if my answer correct or not.

Jyrki Lahtonen
  • 133,153
Aakash Kumar
  • 3,480
  • Yes it is, according to wolframalpha – Jan Eerland Aug 24 '16 at 14:50
  • @JanEerland What about my steps ? – Aakash Kumar Aug 24 '16 at 14:52
  • Yes, your answer and your steps are correct. Why doubt them? – N.S.JOHN Aug 24 '16 at 14:56
  • @N.S.JOHN No doubt just verification because I don't know what is the actual answer of this question ? – Aakash Kumar Aug 24 '16 at 14:58
  • 1
    If you are into experimenting (a good idea IMHO, if you are not in a position to study congruences and/or modular arithmetic yet), you can also simply observe that the last digit of powers of $7$ repeat periodically $7^0$ ends in $1$, $7^1$ in a $7$, $7^2$ in a $9$, $7^3$ in a $3$, and then the period of length four repeats. So $7^{802}$ will share its last digit with $7^2$. Powers of $3$ also repeat their last digits in a period of length four. Meaning that $3^{683}$ has the same last digit as $3^3$. Given this the rest is easy. Your solution is, of course, correct. – Jyrki Lahtonen Aug 24 '16 at 15:53
  • @JyrkiLahtonen Really a great method , Instead of $3^3$ it will be $3^1$ – Aakash Kumar Aug 24 '16 at 16:06

3 Answers3

4

Yes, your proof using the Binomial Theorem is correct. It is simpler using congruences

$$\begin{align} {\rm mod}\ 10\!:\,\ \color{#0a0}{7^{\large 2}}\equiv \color{#c00}{-1}\equiv \color{#0a0}{3^{\large 2}}\ \Rightarrow\, &\ \ (\color{#0a0}{7^{\large 2}})^{\large 401}\!-3(\color{#0a0}{3^{\large 2}})^{\large 341}\\ \equiv\ &(\color{#c00}{-1})^{\large 401}-3(\color{#c00}{-1})^{\large 341}\\ \equiv\ &\ \, {-}1\ \ \ + \ \ \ 3\\ \equiv\ &\ \ \ \ 2\end{align}\qquad\qquad $$

This is precisely the same as your proof, except we eliminated the Binomial Theorem in favor of congruences. Notice how the BT calculation becomes obvious in congruence language, reducing to the trivial result that $\,{\rm mod}\ 10\!:\ (10j\!-\!1)^{2n+1}\equiv (-1)^{2n+1}\equiv {-}1.\ $ Similarly congruence arithmetic serves to trivialize many other arithmetical computations.

Bill Dubuque
  • 272,048
2

Okay, after reading the comments I realize my answer is completely out of the experience level of the OP. But read ahead for a taste of exciting things to come.

=====

Very nice!

I want to introduce you to the idea of Fermat's Little Thereom however.

If $\gcd(a, m) = 1$. And $\phi(m) = $ the number of natural numbers less than $m$ that are relatively prime to $m$ then:

$a^{\phi (m)} \equiv 1 \mod m$

(or in other words $a^{\phi(m)} = km + 1$ for some $k$.)

So... as $1,3,7$ and $9$ are relatively prime to $10$ so $\phi(10) = 4$. And $\gcd(7,10) = \gcd(3,10) = 1$.

So $7^4 = 1 \mod 10$ ($7^4 = 2401$) and $3^4 \equiv 1 \mod 10$ ($3^4 = 81$).

So $7^{802} - 3^{683} = 7^{2 + 4k} - 3^{3 + 4j}$

$= 7^2*(7^4)^k - 3^3*(3^4)^j \equiv 7^2*1^k - 3^3*1^j \mod 10$

$\equiv 49 - 27 \mod 10 \equiv 9 -7 \mod 10 = 2 \mod 10$

So $2$ is the last digit.

.........

Okay, I admit, now that I've typed the whole thing out that seems a LOT more complicated than your elegant fast solution.

But it's useful to know.

If I asked "what is the remainder when $8^{386} - 6^{216}$ is divided by $13$" it might be easier to use Fermat's Little Theorem, rather than "$8^2 = 64 = 5*13 - 1$ and $6^6 = 46656 = 3589*13 - 1$ so $(-1)^{193} - (-1)^36 = -1 -1 =-2$ so $11$ is the remainder"

[$13$ is prime so all numbers less than $13$ are relatively prime so $\phi(13) = 2$. So $8^{386} \equiv 1 \mod 13$ and $6^216 \equiv 1 \mod 13$.

[So $8^{386=2 + 12k} - 6^{216=12j} \equiv 8^2 - 1 \mod 13$

[$\equiv 63 \mod 13 \equiv 11 \mod 13$]

fleablood
  • 124,253
1

The last digit of 7^802 is the same as 7^2, which is 9. The last digit of 3^683 is the same as 3^3, which is 7. Then 9-7 = 2.