#include <bits/stdc++.h>
using namespace std;
int n;
int main() {
  int k, a, b;
  while (cin >> k >> a >> b) {
    int ans = 0;
    ans += a / k;
    ans += b / k;
    if (a % k != 0 && b < k) ans = -1;
    if (b % k != 0 && a < k) ans = -1;
    cout << ans << endl;
  }
  return 0;
}
