#include<bits/stdc++.h>
using namespace std;
typedef long long int64;

vector< bool > get_prime(int n){
  vector< bool > prime( n + 1, true);
 
  if(n >= 0) prime[0] = false;
  if(n >= 1) prime[1] = false;
 
  for(int i = 2; i * i <= n; i++){
    if(prime[i]){
      for(int j = i + i; j <= n; j += i) prime[j] = false;
    }
  }
 
  return prime;
}

int main() {
  vector< bool > prime = get_prime(10000);
  int m, a, b;
  while(cin >> m >> a >> b, m) {
    int bestA = 0, bestB = 0;
    for(int i = 1; i <= 10000; i++) {
      if(!prime[i]) continue;
      for(int j = i; j <= 10000 && i * j <= m; j++) {
        if(!prime[j]) continue;
        if(a * j > i * b) continue;
        if(bestA * bestB < i * j) {
          bestA = i; bestB = j;
        }
      }
    }
    cout << bestA << " " << bestB << endl;
  }
}