#include <bits/stdc++.h>
using namespace std;
signed main() {
  ios_base::sync_with_stdio(false);
  long long n, m, k;
  cin >> n >> m >> k;
  long long a[m];
  for (long long i = 0; i < m; i++) cin >> a[i];
  long long s = 0, ans = 0, km = k;
  for (long long i = 0; i < m; i++) {
    if (a[i] <= k) {
      if (s == 0) ans++;
      s++;
    } else {
      if (k + s >= a[i]) {
        k = k + s;
        s = 0;
        i--;
      } else {
        long long y = (a[i] - k - s) / km;
        if ((a[i] - k - s) * 1.0 / km != (a[i] - k - s) / km) y++;
        k = k + s + km * (y);
        s = 0;
        i--;
      }
    }
  }
  cout << ans;
}
