from Crypto.Util.number import *
import os

flag = os.getenv("FLAG")
flag = b"flag{wow}"
flag = str2long(flag)
p = getPrime(64)
q = getPrime(64)
n = p * q
e = 65537
print(n)
phi = (p - 1) * (q - 1)
d = inverse(e, phi)
cipher = pow(flag, e, n)
print(cipher)
flag = pow(cipher, d, n)
flag = long_to_bytes(flag)
print(flag)