Degree
Medium
Execution time limit is 1 second
Runtime memory usage limit is 64 megabytes
To assess her students' counting abilities, Maria Ivanovna gives them the same challenge each year: for a given natural number A, determine the smallest natural number N such that N raised to the power of N (N multiplied by itself N times) is divisible by A. The only variation from year to year and student to student is the number A.
You've decided to assist future students by writing a program to solve this problem.
Input
The input consists of a single number A (1 ≤ A ≤ 1000000000). This range is provided just in case Maria Ivanovna decides to challenge someone with a particularly large number.
Output
Output a single number N.
Examples
Input #1
Answer #1
Submissions 722
Acceptance rate 21%