A somewhat more general proof involves the use of the Chinese remainder theorem and the fact that 4 is divisible by the order of the multiplicative group of both integers mod 2 and mod 5. Therefore x^5 = x mod 2 and x^5 = x mod 5 for all x, and as a consequence x^5 = x mod 10 for all x.
This construction seems to fail if the base isn't square free. In particular in base 4 the number 2 has as powers 2, 10, 20, 100 etc.