One proof: Let n=10y+x. (Any positive integer can be represented this way. e.g. 119=10(11)+9)
Then `(10y+x)^5=(10y)^5+5(10y)^4x+10(10y)^3x^2+10(10y)^2x^3+5(10y)x^4+x^5 ` I used the binomial expansion, but you will get the same result if you multiply `(10y+x)(10y+x)(10y+x)(10y+x)(10y+x)` carefully.
The key point is that every term except `x^5` must be a factor of 10; thus we can rewrite the expression as `(10y+x)^5=10z+x^5` . This means we are only concerned with the one's digit of n.
Now you can use exhaustion -- show that for every number `0<=k<=9` that the last digit of `k^5` is `k` :
Thus the result holds.
** e.g. if n=119, `119^5=23863477550+59049=10(2386347755)+59049`
`119^5=23863536599` ends in 9 as required.