#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, a, b;
  cin >> n >> a >> b;
  int x = a;
  while ((a / x + b / x) < n) x--;
  if (a < x)
    cout << a;
  else if (b < x)
    cout << b;
  else
    cout << x;
}
