1. ## 2 Modulo questions

We're working with modulos in my number theory class, so I'm sure that's how I am supposed to go about doing these problems. I just can't think of the proper approach...

a)Find the remainder when 5^10 is divided by 19.

b)Find the final digit of 1! + 2! + 3! + ... + 10!

2. These questions usually call for a divide and conquer approach. That is, simplify the problem by breaking it into bits.
a)Find the remainder when 5^10 is divided by 19.
Note that $5^{10} = (5^2)^5$, and that $5^2 \equiv 25 \equiv 6 \pmod{19}$. Thus $(5^2)^5 \equiv 6^5 \pmod{19}$. Note that $6^5 = 6^2 \times 6^2 \times 6^1$, and $6^2 \equiv 36 \equiv 17 \pmod{19}$. So $6^5 \equiv 17 \times 17 \times 6 \pmod{19}$. Note that $17^2 \equiv 289 \equiv 4 \pmod{19}$, so $17^2 \times 6 \equiv 4 \times 6 \equiv 24 \equiv 5 \pmod{19}$. So $5^{10} \equiv 5 \pmod{19}$.

b)Find the final digit of 1! + 2! + 3! + ... + 10!
To find the last digit of this expression, consider it modulo 10 (for example, the last digit of 718 is $718 \equiv 8 \pmod{10}$). Let's start with the small factorials : $1! = 1$, $2! = 2$, $3! = 6$. Now $4! \equiv 3! \times 4 \equiv 6 \times 4 \equiv 24 \equiv 4 \pmod{10}$. Next one : $5! \equiv 4! \times 5 \equiv 4 \times 5 \equiv 20 \equiv 0 \pmod{10}$. Continue like this up to 10! (note that $10! \equiv 0 \pmod{10}$ since it divides 10) ,then sum up all the last digits and take the last digit of this sum and you are done

Does it make sense ?

3. 5! up to 10! will all be congruent to 0 (mod 10) right?

5! = 4! x 5 = 4 x 5 = 20 = 0 (mod 10)
6! = 5! x 6 = 0 x 6 = (0 mod 10)
7! = 6! x 7 = 0 x 7 = (0 mod 10)
...and so on

So 1+2+6+4 = 13 which means my answer is 3?

4. Yes indeed you are right, since $5!$ divides $2$ and $5$ so it divides $10$. And so the last digit of this sum of factorials is indeed $3$

5. Hello, jzellt!

You are right!

b)Find the final digit of $S \;=\;1! + 2! + 3! + 4! + \hdots + 10!$

We have: . $S \;=\;1 + 2 + 6 + 24 + 5! + 6! + \hdots + 10!$

$\text{Hence: }\;S \;=\;33 + \underbrace{5! + 6! + \hdots + 10!}_{\text{All of these end in 0}}$
. .
All the factorials, starting with 5!, contain a factor of 10 (at least).

Therefore, $S$ ends in 3.