You are viewing a single comment's thread. Return to all comments →
import math a = int(input()) b= int(input()) m = int(input()) d = math.pow(a,b) print(math.floor(d)) mod = d % m print(math.floor(mod))
Seems like cookies are disabled on this browser, please enable them to open this website
Power - Mod Power
You are viewing a single comment's thread. Return to all comments →
import math a = int(input()) b= int(input()) m = int(input()) d = math.pow(a,b) print(math.floor(d)) mod = d % m print(math.floor(mod))