#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 7;
long long n, m, k;
const long long z = 9e18;
long long a[maxn];
int main() {
  cin >> n >> m >> k;
  for (int i = 1; i <= m; i++) cin >> a[i];
  long long same = 0;
  long long sum = 1;
  long long ans = 0;
  long long temp = 1;
  a[m + 1] = z;
  for (int i = 1; i <= m + 1;) {
    long long x = (a[i] - temp) / k;
    if (x == same) {
      sum++, i++;
    } else {
      if (sum - temp) ans++;
      temp = sum;
      same = (a[i] - temp) / k;
    }
  }
  cout << ans << endl;
  return 0;
}
