#include <bits/stdc++.h>
using namespace std;
template <typename T>
void rin(T &t) {
  t = 0;
  int k = 1;
  char c = getchar();
  while (!isdigit(c)) {
    if (c == '-') k = -1;
    c = getchar();
  }
  while (isdigit(c)) {
    t = t * 10 + c - '0';
    c = getchar();
  }
  t *= k;
}
long long n, m, k;
const int maxn = 1e5 + 5;
long long p[maxn];
int main() {
  rin(n);
  rin(m);
  rin(k);
  for (int i = 1; i <= m; i++) rin(p[i]);
  long long ans = 0, Last = 0, i = 1, tmp = p[1];
  while (i <= m) {
    ans++;
    for (i; i <= m && (tmp - Last - 1) / k == (p[i] - Last - 1) / k; i++)
      tmp = p[i];
    Last = --i;
    tmp = p[i + 1];
    i++;
  }
  cout << ans;
  return 0;
}
