#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int a, b, k;
  cin >> k >> a >> b;
  if (a < b) swap(a, b);
  if (a % k == 0)
    cout << a / k + b / k << endl;
  else if (a % k != 0 and b >= k)
    cout << a / k + b / k << endl;
  else
    cout << -1 << endl;
}
