#include <stdio.h>

int main()
{
	int m, a, b, p, q, max;
	int primeTable[1300];
	int index = 0;
	for (int i = 2; i < 10000; i++)
	{
		for (int j = 0; j < index; j++)
		{
			if (i % primeTable[j] == 0)
				goto BREAK_1;
		}
		primeTable[index] = i;
		index++;
	BREAK_1:;
	}
	for (; (scanf("%d %d %d", &m, &a, &b) && m != 0); printf("%d %d\n", p, q))
	{
		p = q = max = 0;
		for (int i = 0; primeTable[i] < 320; i++) //319*319=101761
		{
			for (int j = i; j < index; j++)
			{
				if (primeTable[i] * primeTable[j] > m)
					break;
				if ((double)primeTable[i] / (double)primeTable[j] >= (double)a / (double)b && primeTable[i] * primeTable[j] > max)
				{
					p = primeTable[i];
					q = primeTable[j];
					max = p * q;
				}
			}
		}
	}
	return 0;
}
