# cook your dish here
import math
n = int(input())
mi = 10000000007
for i in range(1,int(math.sqrt(n))+1):
    if i==n/i:
        continue
    if n%i==0:
        m = max(i,n/i)
        mi = min(mi,m)
if n==1:
    print(1,1)
else:
    print(int(n/mi),int(mi))