Power of Divisors

아직 제출이 없습니다시간 제한1초메모리 제한2048 MB

문제

Consider a positive integer nn. Let f(n)f(n) be the number of positive integer divisors of nn. For example, if n=8n=8 then f(n)=4f(n)=4, since the divisors of 88 are 11, 22, 44 and 88.

Now, consider a positive integer xx. What is the smallest value of nn such that nf(n)=xn^{f(n)}=x?

입력

The single line of input contains a single integer xx (1x10181 \le x \le 10^{18}). This is the xx of the statement above.

출력

Output a single integer, which is the smallest value of nn such that nf(n)=xn^{f(n)}=x, or 1-1 if no such value of nn exists.