#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  long long int n, m, k;
  long long int p[100000];
  cin >> n >> m >> k;
  for (int i = 0; i < m; i++) {
    cin >> p[i];
  }
  long long int kol = (p[0] / k);
  if (p[0] % k != 0) {
    kol++;
  }
  long long int ans = 1;
  long long int cur = 0;
  long long int val = 0;
  for (int i = 0; i < m; i++) {
    if (p[i] - val <= kol * k) {
      cur++;
    } else if (p[i] - val > kol * k) {
      if (cur > 0) {
        ans++;
      }
      val = val + cur;
      kol = (p[i] - val) / k;
      if ((p[i] - val) % k != 0) {
        kol++;
      }
      cur = 0;
      i--;
    }
  }
  cout << ans;
  return 0;
}
