#include <bits/stdc++.h>
using namespace std;
int n, i, j, m, x, y;
const int N = 1e5 + 7;
int t, S, q, ans;
int main() {
  ios_base::sync_with_stdio(false);
  cin >> t >> S >> q;
  while (S < t) {
    S *= q;
    ans++;
  }
  cout << ans;
}
