from __future__ import print_function
from sys import stdin
import math

def printf(str, *args):
	print(str % args, end='')

while True:
	D=1
	printf("약수를 구할 N 값을 주세요. \n N= ");
	N=int(stdin.readline())
	while(D < math.sqrt(N)):
		if N%D==0:
			printf("%d %d " %(D, N/D))
		D=D+1
	printf("\n")
stdin.readline()