#include <bits/stdc++.h>
template <typename T, typename U>
inline void swap(T &a, U &b) {
  a = a ^ b;
  b = a ^ b;
  a = a ^ b;
}
inline void swap(int &a, int &b) {
  a = a ^ b;
  b = a ^ b;
  a = a ^ b;
}
inline void smax(int &a, int b) {
  if (b > a) a = b;
}
inline void smin(int &a, int b) {
  if (b < a) a = b;
}
inline int gcd(int a, int b) {
  if (a < b) swap(a, b);
  while (b > 0) {
    a %= b;
    swap(a, b);
  }
  return a;
}
long long nchose(int a, int b) {
  long long ans = 1;
  smax(a, b - a);
  int p = 2;
  for (int i = (b - a + 1); i <= (b); i++) {
    ans *= (long long)i;
    while (p <= a && ans % p == 0) ans /= p++;
  }
  return ans;
}
using namespace std;
long long a, b, m, res;
int main() {
  cin >> a >> b >> m;
  if (a < b) swap(a, b);
  if (a < m && a < 1) {
    cout << -1;
    return 0;
  }
  while (a < m) {
    if (b < 0) {
      res -= b / a;
      b -= b / a * a;
    }
    res++;
    b = a + b;
    if (b > a) swap(a, b);
  }
  cout << res;
}
