#include <bits/stdc++.h>
long long int power(long long int x, long long int b) {
  long long int p = 1;
  while (b > 0) {
    if (b & 1) {
      p = p * x;
      p %= 9000000000000000000;
    }
    b >>= 1;
    x *= x;
    x %= 9000000000000000000;
  }
  return p % 9000000000000000000;
}
using namespace std;
struct lex_compare {
  bool operator()(const pair<long double, long long int> p1,
                  const pair<long double, long long int> p2) {
    return (p1.first == p2.first) ? p1.second < p2.second : p1.first > p2.first;
  }
};
long long int divd(long long int a, long long int b, long long int m) {
  return (b / m) - (a - 1) / m;
}
long long int rec(long long int arr[], long long int y) {
  sort(arr, arr + 3);
  if (arr[0] == y && arr[1] == y && arr[2] == y) return 0;
  if (arr[2] > y) return 1e15;
  arr[0] = min(arr[1] + arr[2] - 1, y);
  return 1 + rec(arr, y);
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  ;
  long long int x, y;
  cin >> x >> y;
  long long int arr[3] = {y, y, y};
  long long int ans = rec(arr, x);
  cout << ans << "\n";
  return 0;
}
