#include <bits/stdc++.h>
using namespace std;
const int INF = int(1e9);
const double EPS = 1e-8;
struct debugger {
  template <typename T>
  debugger& operator,(const T& v) {
    cerr << v << " ";
    return *this;
  }
} dbg;
int main() {
  std::ios_base::sync_with_stdio(false);
  int x, y;
  cin >> y >> x;
  vector<int> side(3, x);
  int res = 0;
  int turn = 0;
  while (1) {
    if (side[turn] != y) {
      res += 1;
      int len = 0;
      for (int i = 0; i < 3; i++)
        if (i != turn) len += side[i];
      side[turn] = min(y, len - 1);
    }
    bool valid = true;
    for (int i = 0; i < 3; i++)
      if (side[i] != y) valid = false;
    if (valid) break;
    turn = (turn + 1) % 3;
  }
  cout << res << endl;
  return 0;
}
