#include <bits/stdc++.h>
using namespace std;
int read() {
  int x = 0, f = 0;
  char ch = 0;
  while (!isdigit(ch)) f |= (ch == '-'), ch = getchar();
  while (isdigit(ch)) x = (x << 3) + (x << 1) + (ch ^ 48), ch = getchar();
  return f ? -x : x;
}
void write(int x) {
  if (x < 0) putchar('-'), x = -x;
  if (x >= 10) write(x / 10);
  putchar(x % 10 + '0');
}
int x, y, na, nb, nc;
int tot, ans;
int main() {
  x = read(), y = read();
  na = nb = nc = y;
  while (na < x || nb < x || nc < x) {
    tot++;
    ans++;
    if (tot == 1) na = nb + nc - 1;
    if (tot == 2) nb = na + nc - 1;
    if (tot == 3) nc = na + nb - 1, tot = 0;
  }
  write(ans);
  return 0;
}
