import java.util.*;
public class Main {
	public static void main(String[] args) {
		Scanner sc=new Scanner(System.in);
		
			int n=sc.nextInt();
			int flag=0,i=0,j=0;
			for(i=1;i<=n;i++)
                         {
                         for(j=1;j<=n;j++)
                          {
                          if(i*j==n)
                           {
                            flag=1;
                            break;
                            }
                           } 
                           if(flag==1)
                            break;
                            }
                          System.out.print(i+" "+j);
                             
	}
}
