#include <bits/stdc++.h>
using namespace std;
int n;
int main() {
  cin >> n;
  for (int i = sqrt(n); i <= n; ++i) {
    if (!(n % i)) {
      cout << min(i, n / i) << " " << max(i, n / i);
      return 0;
    }
  }
}
