// AOJ 1232: Calling Extraterrestrial Intelligence Ag...
// 2017.10.14 bal4u@uu

#include <stdio.h>
#include <math.h>

#define MAX  100000
#define SQRT 316     // sqrt(MAX)
char prime[MAX+5], *pmax = prime + MAX;

void mkprime()
{
	int k;
	register char *p, *q;
//	prime[1] = 1, prime[2] = 0;
//	for (p = prime + 4; p <= pmax; p += 2) *p = 1;
	for (k = 3, p = prime + 3; k <= SQRT; k += 2, p += 2)
		if (!*p) for (q = p + k; q <= pmax; q += k) *q = 1;
}

int main()
{
	int m, a, b, p, q;
	int k, t, max, pmax, qmax;

	mkprime();
	while (scanf("%d%d%d", &m, &a, &b) && m > 0) {
		k = (int)sqrt(m); if (k > 2 && !(k & 1)) k--;
		while (prime[k]) k -= 2;
		for (max = 0, p = k; p >= 2; p-=2) if (!prime[p]) {
			q = m/p, t = p*b/a;
			if (q > t) q = t;
			if (q > 2 && !(q & 1)) q--;
			while (prime[q]) q -= 2;
			if ((t = p*q) > max) max = t, pmax = p, qmax = q;
		}
		printf("%d %d\n", pmax, qmax);
    }
    return 0;
}