def gcd(a,b):
    if(a==0):
        return b
    return gcd(b%a,a)

def lcm(a,b):
    if(a==0 or b==0):
        return 
    return (a*b)//gcd(a,b)

n=int(input())
i=1
ans=0
while(i*i<=n):
    if(n%i==0 and lcm(i,n/i)==n):
        ans=i
    i+=1
print(ans,n//ans)