const main = (inputs) => {

  const array = inputs[0].split(" ");
  var N = Number(array[0]);
  var A = Number(array[1]);
  var B = Number(array[2]);
  var answer = 0;
  for (var i = 1; i < N; i++) {
    if (A === 0) break;
    if (i <= A) {
      answer = answer + 1;
    } else if (i === A + B - 1) {
      A = A + A + B;
      B = A + A + B;
    }
  }
  console.log(answer);
}

main(require('fs').readFileSync('/dev/stdin', 'UTF-8').trim().split("\n"));