import math

def LCM(a, b):
    return abs(a*b) // math.gcd(a, b)
        

def operator(t):
    min_=math.inf
    val=math.floor(t**(0.5))
    for i in range(val,0,-1):
        a,b=divmod(t,i)
        if b==0:
            if t==LCM(a,i) and min_>max(i,a):
                return ' '.join(map(str,[i,a]))
t=int(input())
print(operator(t))