import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		long x = sc.nextLong();
		sc.close();
		long[] a = new long[100000];
		long k = 2;
		int i = 1;
		int c = 1, d = 1;
		if (x == 1) {
			System.out.print("1 1");
			return;
		} else {
			a[0] = 1;
			while (x != 1) {
				if (x % k == 0) {
					a[i] = k;
					i++;
					x = x / k;
				} else {
					k++;
				}
			}
		}
		for (int j = 1; j < i; j++) {
			c *= a[j];
			if (a[j + 1] != a[j]) {
				for (int h = j + 1; h < i; h++) {
					d *= a[h];
				}
				break;
			}
		}
		if (c > d) {
			int t = c;
			c = d;
			d = t;
		}
		System.out.print(c + " " + d);
	}
}

 			 		  	       	 	 					  		