#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  int x, y;
  cin >> y >> x;
  int a[3];
  for (int i = 0; i < 3; i++) {
    a[i] = x;
  }
  int u = 0;
  while (a[0] != y) {
    a[0] = min(a[2] + a[1] - 1, y);
    sort(a, a + 3);
    u++;
  }
  cout << u;
}
