Why for numbers with last digits $0, 2, 3, 5, 7$ and $8, (n^x +n^{x+2})/5$ is a whole number and for numbers with last digits $1, 4, 6$ and $9, (n^x +n^{x+2})/5$ is not a whole number?
Asked
Active
Viewed 17 times
0
-
Welcome to Mathematics Stack Exchange. If the last digit of $n$ is divisible by $5$ then $n^x$ and $n^{x+2}$ are both divisible by $5$, so their sum is. If $n\equiv2\pmod5$ then $n^x+n^{x+2}\equiv n^x(1+2^2)\equiv0\pmod5$; if $n\equiv3\pmod5$ then $n^x+n^{x+2}\equiv n^x(1+3^2)\equiv0\pmod5$ – J. W. Tanner Apr 20 '20 at 21:28
1 Answers
1
Because $n$ is congruent to its last digit modulo $10$, hence also modulo $5$, and because in the factorisation $$n^x+n^{x+2}=n^x(1+n^2),$$ you can check the second factor is congruent to $0\bmod 5$ only if the digit is $2,3,7,8$, and the first factor is divisible by $5$ if and only if the last digit is $0$ or $5$.
Bernard
- 175,478