N=int(input()) S=int((N**0.5)) a=1 for i in range(1,S+1): if N%i**2==0: a=i print(a,N//a**2)