Given two natural numbers $a$ and $b$, determine the last digit of the number $a^b$.
Write a program that:
- reads the base $a$ and the exponent $b$,
- determines the last digit of $a^b$,
- prints the result.
Input
The first and only line contains two integers $a$ and $b$ ($1 \le a, b \le 1\,000\,000\,000$) separated by a single space.
Output
Your program should print only the last (least significant) digit of the number $a^b$ in decimal notation.
Examples
Input 1
2 3
Output 1
8