n = int(input()) for i in range(int(n ** 0.5) + 1, -1, -1): if n % i ** 2 == 0: print(i, n // (i ** 2)) exit() print(1, n)