#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, m, k;
  cin >> n >> m >> k;
  long long arr[m];
  for (int i = 0; i < m; i++) {
    cin >> arr[i];
    arr[i]--;
  }
  long long ans = 0;
  long long x = 0;
  for (int i = 0; i < m;) {
    long long num = 0;
    long long cur = (arr[i] - x) / k;
    for (int j = i; j < m; j++) {
      if ((arr[j] - x) / k != cur) break;
      i++;
      num++;
    }
    ans++;
    x += num;
  }
  cout << ans;
  return 0;
}
