import math int_first = int(input()) numer = int(math.sqrt(int_first)+1) while numer > 0: numer_double = int(numer*numer) if int_first%numer_double==0: sho = int(int_first/numer_double) result = str(int(numer))+" "+str(sho) break numer = numer -1 print(result)