5. What can be the last digit of the sum $3^{m}+7^{n}$, where $m, n \in \mathbb{N}$?

## Tasks worth 10 points:
5. What can be the last digit of the sum $3^{m}+7^{n}$, where $m, n \in \mathbb{N}$?

## Solution.

For $m \in \mathbb{N}$, we get a sequence of powers with base 3:

$$
3^{1}, 3^{2}, 3^{3}, 3^{4}, \ldots
$$

whose last digits are

$$
3,9,7,1
$$

which cyclically alternate.

For $n \in \mathbb{N}$, we get a sequence of powers with base 7:

$$
7^{1}, 7^{2}, 7^{3}, 7^{4}, \ldots
$$

whose last digits are

$$
7,9,3,1
$$

which cyclically alternate.

Consider all possible combinations of the last digits of the addends.

| last digit |  |  |
| :---: | :---: | :---: |
| of addends | sum $3^{m}+7^{n}$ |  |
| 1 | 1 | 2 |
| 1 | 3 | 4 |
| 1 | 7 | 8 |
| 1 | 9 | 0 |
| 3 | 3 | 6 |
| 3 | 7 | 0 |
| 3 | 9 | 2 |
| 7 | 7 | 4 |
| 7 | 9 | 6 |
| 9 | 9 | 8 |

The last digit of the sum belongs to the set $\{0,2,4,6,8\}$.

Note: The student does not have to list all combinations but can conclude that, since we are adding two odd numbers, the last digit of the sum must be even, and each even digit can be achieved, for example, $1+1=2,1+3=4,3+3=6,1+7=8,1+9$ gives 0.

The last two points are awarded for the argument showing how to achieve each of the 5 possible digits, with 1 point given if the argument is correct for 4 possible digits, and 0 points otherwise.