#include <bits/stdc++.h>
int main() {
  FILE *fi, *fout;
  int n, d, a, b;
  fi = stdin;
  fout = stdout;
  fscanf(fi, "%d", &n);
  d = 1;
  while (d * d <= n) {
    if (n % d == 0) {
      a = d;
      b = n / d;
    }
    d++;
  }
  fprintf(fout, "%d %d ", a, b);
  return 0;
}
