Compute a^b mod 1337, where the exponent b is a huge number given as a list of its decimal digits (most significant digit first, for example [1, 0] means 10). The list is not empty.
For a = 2 and b = [1, 0] the answer is 1024; for a = 2147483647 and b = [2, 0, 0] it is 1198.
Example 1
Input:
super_pow(2, [1, 0])
Output:
1024
Example 2
Input:
super_pow(2147483647, [2, 0, 0])
Output:
1198
1 <= a <= 2**31 - 11 <= len(b) <= 20000 to 9; b has no leading zero unless b = [0].No results yet
Run your code to check it against the examples, or submit to run every test.