from math import gcd
t=int(input())
c=[1,t]
d=t
for i in range(1,int(pow(t,0.5))+1):
    if not t%i:
        x=i
        y=t//i
        
        e=gcd(x,y)
        g=min(x,y)*e
        h=max(x,y)
        if (g*h)//gcd(g,h)==t and max(g,h)<d:
            d=max(g,h)
            c=[g,h]
print(*c)
        
        
        
        
