• [D] hkhv in Love

  • 时间限制: 1000 ms 内存限制: 65535 K
  • 问题描述
  • hkhv is in love with lovely numbers! A positive integer x is called lovely if and only if there is no such positive integer a > 1 such that a*a is a divisor of x.
    skyv95 has a number store! In his store, he has only divisors of positive integer n (and he has all of them). As a birthday present, skyv95 wants to give her a lovely number from his store. He wants this number to be as big as possible.

  • 输入
  • The first and only line of input contains one integer, n (1 <= n <= 10^12).
  • 输出
  • Print the answer in one line.
  • 样例输入
  • 10
    12
    
  • 样例输出
  • 10
    6
  • 提示
  • In first sample case, there are numbers 1, 2, 5 and 10 in the shop. 10 isn't divisible by any perfect square, so 10 is lovely.
    
    In second sample case, there are numbers 1, 2, 3, 4, 6 and 12 in the shop. 12 is divisible by 4 = 2*2, so 12 is not lovely, while 6 is indeed lovely.
  • 来源
  • Recoder
  • 操作

显示春菜