#include <bits/stdc++.h>
using namespace std;
int main() {
  int x, y;
  cin >> x >> y;
  int ans = 0;
  int B[3];
  B[0] = y;
  B[1] = y;
  B[2] = y;
  while (!(B[0] == x && B[1] == x && B[2] == x)) {
    if (ans % 3 == 0) {
      B[0] = min(x, B[1] + B[2] - 1);
    } else if (ans % 3 == 1) {
      B[1] = min(x, B[0] + B[2] - 1);
    } else {
      B[2] = min(x, B[0] + B[1] - 1);
    }
    ans++;
  }
  cout << ans << endl;
  return 0;
}
