You are given three integers , , and . Output the remainder when A^B (the -th power of ) is divided by .
The only line of the input file contains three integers: , , (1 \leq A, B, C \leq 10^{18}). The numbers are separated by spaces.
The output file must contain one non-negative integer less than — the answer to the problem.
Example 1