Quote:

Originally Posted by **Eucler** It's closely related to the fact that for every integer x, the last digit of x^5 is the same as the last digit of x. (This is a consequence of Fermat's Little Theorem, if you're familiar with that.)
In more detail:
Being divisible by 10 means divisible by 2 and divisible by 5.
It's not too hard to see that x + x^2 + x^3 + x^4 is always divisible by 2.
Divisibility by 5 is a bit trickier, but you can use the formula for sums of terms in geometric progression to get x + x^2 + x^3 + x^4 = (x^5-x)/(x-1). The numerator is always divisible by 5 by the fact mentioned at the start of this post. So we're done, provided that the denominator is not also divisible by 5 (which could cancel with the 5 in the numerator).
So this works as long as x - 1 is not a multiple of 5, i.e. it works for any natural number x not ending in 1 or 6 (which is slightly more general than the pattern you noticed).
If you're willing to get a bit more crazy, you can use similar reasoning to show such things as:
For every natural number x ending in 3, 7, or 9, the sum x + x^2 + x^3 + ... + x^20 will be divisible by 100. |

Eucler, thank you (and thank you for taking my question seriously). That does explain a lot. I had eventually noted that for integers ending in 9, 5, or 4, the sum of any two consecutive powers is always divisible by 10, and that for those ending in 1 and 6, you have to add 10 (for 1) and 5 (for 6) consecutive powers to get there (for obvious reasons - at least now).

I am aware that there's not anything terribly useful here, but I find this kind of stuff intriguing (I'm also a big prime-number fanatic). I might try looking at this in another base (octal or base 6 maybe?) just to see what similarities and/or variations may occur.

Thanks again.