#include <bits/stdc++.h>
using namespace std;
inline int in() {
  int x;
  scanf("%d", &x);
  return x;
}
template <typename T>
istream &operator>>(istream &in, vector<T> &vec) {
  for (int i = 0; i < vec.size(); ++i) in >> vec[i];
  return in;
}
template <typename T>
ostream &operator<<(ostream &out, const vector<T> &vec) {
  for (int i = 0; i < vec.size(); ++i) out << vec[i] << " ";
  return out;
}
const int INT = 1e5;
long long tr[4 * INT];
long long eds = 0;
const int INF = -1e10;
int main() {
  long long a = in(), b = in(), c = in(), d = 0;
  cout << ((!(b % a) && b || !(c % a) && c || b >= a && c >= a) ? b / a + c / a
                                                                : -1)
       << endl;
  return 0;
}
