For a number $a^{x^{...^n}} $. To find its last digit in a base b,
Imagine that I have this number $a^{x^{y}}$ to simplify the problem. Then I calculate $a^{x} \equiv c \pmod b$ and after that $c^{y} \equiv d \pmod b$ which means that d is the last digit. Am i right?
Thanks !