#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
  long long int num, ans = INT_MAX, temp, multi1 = INT_MAX, multi2 = INT_MAX;
  cin >> num;
  for (long long int i = 1; i <= sqrt(num); i++) {
    if (num % i == 0) {
      temp = num / i;
      if (abs(i - temp) < ans) ans = abs(i - temp), multi1 = i, multi2 = temp;
    }
  }
  cout << multi1 << " " << multi2;
  return 0;
}
