#include <bits/stdc++.h>
using namespace std;
int main() {
  long n, m;
  while (cin >> n >> m) {
    long cnt = 0, ar[10] = {0}, k = 0;
    ar[0] = m;
    ar[1] = m;
    ar[2] = m;
    while (1) {
      sort(ar, ar + 3);
      if (ar[0] >= n) break;
      ar[0] = min(n, ar[1] + ar[2] - 1);
      cnt++;
    }
    cout << cnt << endl;
  }
  return 0;
}
