from math import sqrt
from math import ceil
x=int(input())
ans=x
for i in range(1,ceil(sqrt(x))):
    if x%i==0:
        a=i
        b=x//i
        c=max(a,b)
        if c<ans:
            ans=c
print(min(ans,x//ans),max(ans,x//ans))
    
