import java.util.Scanner;

public class File {

	public static void main(String[] args) {
		Scanner scn = new Scanner(System.in);
		
		int x = scn.nextInt();
		for(int i=(int) Math.sqrt(x);i>0;i++) {
			if(x%i==0)
			System.out.println(i+" "+x/i);
			break;
		}
		
	}
}