import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); long x = sc.nextLong(); sc.close(); while(x%4==0) x=x/4; for(long i=3; i*i <= x; i += 2){ while(x%(i*i) == 0) x=x/(i*i); } System.out.println(x); } }