#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, m, k;
  cin >> n >> m >> k;
  long long kk = k;
  deque<long long> A;
  for (int i = 0; i < m; i++) {
    long long a;
    cin >> a;
    A.push_back(a);
  }
  long long sum = 0;
  while (A.size() > 0) {
    sum++;
    long long no = 0;
    while (A.size() > 0 && A[0] <= kk) {
      no++;
      A.pop_front();
    }
    if (no > 0) {
      kk += no;
    } else {
      if (A.size() > 0) {
        long long jj = (A[0] - kk + k - 1) / k;
        jj = jj * k;
        kk = kk + jj;
      }
      sum--;
    }
  }
  cout << sum << endl;
}
