~cpp 
// no 113 -  Power of Cryptography  
#include <iostream>
#include <math.h>
using namespace std;
const int LEN = 1001;
int find_length(char * p)
{
	int i;
	for (i = 0; ; i++)
	{
		if (p[i] == '\0')
			break;
	}
	return i;
}
// 가정 - 근사치만 구해도 된다.
double find_lnP(char * p)
{
	double lnP;
	int len = find_length(p);
	lnP = len - 1;
	double temp = 0;
	int i;
	for (i = 0; i < 15; i++)
	{
		if (i == len)
			break;
		temp *= 10;
		temp += (p[i] - '0');
	}	
	lnP += log10(double(temp) / pow(10, i-1));
	return lnP;
}
void process(int n, char * p)
{
	double lnP = find_lnP(p);
	double ex = lnP / n;
	double k = pow(10, ex);
	k += 0.5;
	int result = floor(k);
	cout << result << endl;
}
int main()
{
	int n;
	char p[LEN];
	while (cin >> n)
	{
		cin.get();
		cin.getline(p, LEN, '\n');
		process(n, p);
	}
	return 0;
}