#include <bits/stdc++.h>
using namespace std;
bool f[1000007];
vector<int> prime;
void sieve() {
  f[0] = f[1] = 1;
  for (int i = 2; i < 1000007; ++i) {
    if (f[i]) continue;
    prime.push_back(i);
    for (int j = i * i; i <= 10000 && j < 1000007; j += i) f[j] = 1;
  }
}
vector<int> factor;
void getFactor(int n) {
  for (int i = 2; i <= n / i; ++i) {
    while (n % i == 0) {
      factor.push_back(i);
      n /= i;
    }
  }
  if (n != 1) factor.push_back(n);
}
int MaxSubarray(int arr[], int n) {
  int best = 0, sum = 0;
  for (int i = 0; i < n; ++i) {
    sum = max(arr[i], arr[i] + sum);
    best = max(best, sum);
  }
  return best;
}
long long GCD(long long a, long long b) { return b ? GCD(b, a % b) : a; }
long long LCM(long long a, long long b) { return a / GCD(a, b) * b; }
long long fast_power(long long b, long long p) {
  long long res = 1;
  while (p) {
    if (p % 2) res = (res * b) % 1000000007;
    b = (b * b) % 1000000007;
    p /= 2;
  }
  return res;
}
int n, a, b;
int main() {
  scanf("%d%d%d", &n, &a, &b);
  int st = 0, en = 1e9;
  while (st < en) {
    int mid = (st + en + 1) / 2;
    if (mid > min(a, b))
      en = mid - 1;
    else if (a / mid + b / mid < n)
      en = mid - 1;
    else
      st = mid;
  }
  printf("%d\n", st);
  return 0;
}
