def factor(n): table = [] i = 2 while i * i <= n: if n % i == 0: cnt = 0 while n % i == 0: n //= i cnt += 1 table.append((i, cnt)) i += 1 if n > 1: table.append((n, 1)) return table N = int(input()) a, b = 1, 1 for p, i in factor(N): a *= p ** (i // 2) b *= p ** (i % 2) print(a, b)