M = int(input()) for i in range(2,int(M**(1/2))+1): if M % i == 0: print(i,M//i) exit() print(1,M)