import strutils, math, tables var X = stdin.readline.parseBiggestInt divisors = initTable[int64, int]() for i in 2..X.float.sqrt.int+1: if X mod i.int64 == 0: divisors.add(i.int64, 0) while X mod i.int64 == 0: divisors[i.int64].inc X = X div i.int64 if X > 1: divisors.add(X, 1) var ans = 1.int64 for p in pairs(divisors): var (k, v) = p if v mod 2 == 1: ans *= k echo(ans)