#include <bits/stdc++.h>
using namespace std;
int main() {
  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 j = 0, ans = 0;
  long long i = 0, c;
  while (i < m) {
    c = (a[i] - j + k - 1) / k;
    i++;
    while (i < m && ((a[i] - j + k - 1) / k) == c) i++;
    j = i;
    ans++;
  }
  cout << ans;
}
