what is the ones digit of 9^40?
what is the ones digit of 9^40 ?
$$9^{40}\mod 10\\=( \underbrace{9^2}_{=1\mod 10} )^{20}\mod 10 \qquad | \qquad 9^2\mod 10 =\ 81 \mod 10 =\ 1 \\\\=1^{20}\mod 10 \qquad\qquad | \quad 1^{20} = 1 \\=1\mod 10$$
Note the cycle
9^1 = 9
9^2 = 81
9^3 = 729
9^4 = 6561 and this pattern repeats for every "block" of 4 powers
Note that 40 is evenly divisible by 4, so 9^40 has a "ones" digit that completes this cycle. So....9^40 ends in a "1"