Buggy python submission (verdict: Runtime Error):
n, p = map(int, input().split())
num = int(p ** (1 / n))
for i in range(num + 1, 0, -1):
    p0 = p
    count = 0
    if i == 1:
        print(i)
        break
    for i in range(n):
        if p0 % i == 0:
            p0 //= i
            count += 1
        else:
            break
    else:
        print(i)
        break

Fixed submission:
n,p = map(int,input().split())
dum = round(p**(1/n))
for i in range(dum,-1,-1):
    if p%(i**n) == 0:
        print(i)
        break

Buggy python submission (verdict: Time Limit Exceeded):
n, p = map(int, input().split())
num = round(p ** (1 / n))
for i in range(num + 1, 0, -1):
    if p % (i ** n) == 0:
        print(i)
        break

Fixed submission:
n,p = map(int,input().split())
dum = round(p**(1/n))
for i in range(dum,-1,-1):
    if p%(i**n) == 0:
        print(i)
        break

Buggy python submission (verdict: Time Limit Exceeded):
n, p = map(int, input().split())
if n == 1:
    print(p)
else:
    num = round(p ** (1 / n))
    for i in range(num + 1, 0, -1):
        if p % (i ** n) == 0:
            print(i)
            break

Fixed submission:
n,p = map(int,input().split())
dum = round(p**(1/n))
for i in range(dum,-1,-1):
    if p%(i**n) == 0:
        print(i)
        break

Buggy python submission (verdict: Time Limit Exceeded):
n, p = map(int, input().split())
if n == 1:
    print(p)
else:
    num = int(p ** (1 / n))
    for i in range(num + 1, 0, -1):
        if p % (i ** n) == 0:
            print(i)
            break

Fixed submission:
n,p = map(int,input().split())
dum = round(p**(1/n))
for i in range(dum,-1,-1):
    if p%(i**n) == 0:
        print(i)
        break

Buggy python submission (verdict: Time Limit Exceeded):
n, p = map(int, input().split())
if n == 1:
    print(p)
else:
    for i in range(int(p ** 0.5), 0, -1):
        p0 = p
        count = 0
        for j in range(n):
            if p0 % i == 0:
                p0 //= i
                count += 1
            else:
                break
        else:
            print(i)
            break

Fixed submission:
n,p = map(int,input().split())
dum = round(p**(1/n))
for i in range(dum,-1,-1):
    if p%(i**n) == 0:
        print(i)
        break

Buggy python submission (verdict: Time Limit Exceeded):
n, p = map(int, input().split())
if n == 1:
    print(p)
else:
    for i in range(int(p ** 0.5), 0, -1):
        p0 = p
        count = 0
        for j in range(n):
            if p0 % i == 0:
                p0 //= i
                count += 1
            else:
                break
        else:
            print(i)
            break

Fixed submission:
n,p = map(int,input().split())
dum = round(p**(1/n))
for i in range(dum,-1,-1):
    if p%(i**n) == 0:
        print(i)
        break

Buggy python submission (verdict: Time Limit Exceeded):
import sys
n, p = map(int, input().split())
if n == 1:
    print(p)
else:
    for i in range(10 ** 6, 0, -1):
        p0 = p
        count = 0
        while p0 % i == 0:
            p0 //= i
            count += 1
            if count == n:
                print(i)
                sys.exit()

Fixed submission:
n,p = map(int,input().split())
dum = round(p**(1/n))
for i in range(dum,-1,-1):
    if p%(i**n) == 0:
        print(i)
        break

Buggy python submission (verdict: Time Limit Exceeded):
import sys
n, p = map(int, input().split())
if n == 1:
    print(p)
else:
    for i in range(10 ** 6, 0, -1):
        p0 = p
        count = 0
        while p0 % i == 0:
            p0 //= i
            count += 1
            if count == n:
                print(i)
                sys.exit()

Fixed submission:
n,p = map(int,input().split())
dum = round(p**(1/n))
for i in range(dum,-1,-1):
    if p%(i**n) == 0:
        print(i)
        break

Buggy python submission (verdict: Runtime Error):
n, p = map(int, input().split())
if n == 1:
    print(p)
else:
    for i in range(int(p ** (1 / n)) + 1, 0, -1):
        if p % (i ** n) == 0:
            print(i)
            break

Fixed submission:
n,p = map(int,input().split())
dum = round(p**(1/n))
for i in range(dum,-1,-1):
    if p%(i**n) == 0:
        print(i)
        break

Buggy python submission (verdict: Time Limit Exceeded):
n, p = map(int, input().split())
if n == 1:
    print(p)
else:
    for i in range(int(p ** (1 / n)) + 1, 0, -1):
        if p % (i ** n) == 0:
            print(i)
            break

Fixed submission:
n,p = map(int,input().split())
dum = round(p**(1/n))
for i in range(dum,-1,-1):
    if p%(i**n) == 0:
        print(i)
        break