/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package UVA_Pendientes;
import java.math.BigInteger;
import java.util.Scanner;
/**
*
* @author DAM116
*/
public class UVA00113_PowefOfCrytografy {
public static void main(String[] args) {
Scanner entrada = new Scanner(System.in);
int exp;
BigInteger base;
while (entrada.hasNext()) {
exp = entrada.nextInt();
base = entrada.nextBigInteger();
System.out.println(Math.round(Math.pow(base.doubleValue(), (double)1/exp)));
}
}
}