#include <bits/stdc++.h>
using namespace std;
const int INF = 1e9 + 7;
const int N = 1e5 + 5;
int main() {
  long long int k, a, b;
  scanf("%lld%lld%lld", &k, &a, &b);
  if ((a >= k && b >= k) || (a % k == 0 && a != 0) || (b % k == 0 && b != 0)) {
    cout << (a / k) + (b / k);
  } else {
    cout << -1;
  }
}
