10 5 5
2 3 4 5 6
 1 1 1
1
 1000000000000000000 10 68
9818112234872670 233245257111863071 266483628625876079 375103213040049805 431982380866113633 489732004669478331 501030096787260719 541800997319766183 551892546260532408 696178619227890200
 1000000000000000000 2 1
1 1000000000000000000
 33 32 1
1 2 3 4 5 6 7 8 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
 101 55 10
1 3 5 7 8 9 10 16 18 21 22 23 24 25 27 30 32 35 36 37 38 39 40 43 45 47 49 50 51 52 54 57 59 61 64 66 67 68 69 70 71 72 73 80 83 86 87 88 89 90 91 92 96 97 98
 1000000000000000000 5 1000
1 1000000000 1000000000000 1000000000000000 1000000000000001
 15 15 15
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
 21 21 20
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
 45 43 2
1 2 3 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45
 107 20 13
5 9 20 25 26 30 37 45 51 58 62 73 82 87 89 90 99 101 104 106
 3 2 1
1 2
 1000000000 2 1000000000
1 1000000000
 11 7 3
2 3 4 5 6 7 11
 13 9 4
1 2 3 6 7 8 11 12 13
 1000000000000000000 2 1000000000
102306300054748096 267367244641009859
 16 7 5
2 3 4 5 6 15 16
 35 35 1
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
 1000000000000000000 20 365
31881893160049984 103938857870698567 103962228223609431 140762820261865064 175962215264653912 239086305245565642 354522451098745823 383839975876242372 443471287955807705 478923027151493682 511195154588214957 619570919279066139 677571312513476877 705864797651447277 789633853044745934 867300890280086078 883297431113041450 891736036124527038 937306858250803630 990892290394455512

2
 1
 10
 2
 32
 15
 4
 1
 2
 35
 9
 2
 1
 4
 4
 2
 4
 35
 20

#include <bits/stdc++.h>
using namespace std;
using ll = long long;
ll gcd(ll a, ll b) { return b == 0LL ? a : gcd(b, a % b); }
ll lcm(ll a, ll b) { return (a * b) / gcd(a, b); }
ll mod_pow(ll base, ll power, ll mod) {
  base %= mod;
  ll ret = 1LL;
  while (power) {
    if (power & 1) ret = (ret * base) % mod;
    base = (base * base) % mod;
    power >>= 1;
  }
  return ret;
}
vector<ll> primes_global;
vector<ll> seive(ll _upper_bound = 10000000) {
  bitset<10000007> bs;
  bs.set();
  if (_upper_bound > 10000000) _upper_bound = 10000000;
  vector<ll> primes;
  ll _seive_size = _upper_bound;
  bs[0] = bs[1] = 0;
  for (ll i = 2; i <= _seive_size; i++) {
    if (bs[i]) {
      for (ll j = i * i; j <= _seive_size; j += i) bs[j] = 0;
      primes.push_back(i);
    }
  }
  primes_global = primes;
  return primes;
}
bool is_prime(ll _number) {
  if (primes_global.empty()) seive();
  for (int i = 0; primes_global[i] * primes_global[i] <= _number and
                  i < primes_global.size();
       i++) {
    if (_number % primes_global[i] == 0) return false;
  }
  return true;
}
vector<ll> prime_factors(ll _number) {
  if (primes_global.empty()) {
    seive();
  }
  vector<ll> factors;
  ll pf_idx = 0, pf = primes_global[pf_idx];
  if (is_prime(_number)) {
    factors.push_back(_number);
    return factors;
  }
  while (pf * pf <= _number) {
    if (_number % pf == 0) {
      factors.push_back(pf);
      while (_number % pf == 0) _number /= pf;
    }
    pf = primes_global[++pf_idx];
  }
  if (_number != 1) factors.push_back(_number);
  return factors;
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cin.tie(0);
  ll n, k, m;
  cin >> n >> m >> k;
  vector<ll> in(m + 5, 0);
  for (int i = 1; i <= m; i++) {
    cin >> in[i];
  }
  ll ans = 0;
  ll cur = in[1] / k;
  if (in[1] % k == 0) cur--;
  int i;
  for (i = 2; i <= m; i++) {
    if (ans == 0) {
      ll now = in[i] / k;
      if (in[i] % k == 0) --now;
      if (now > cur) {
        ++ans;
        break;
      }
    } else {
      break;
    }
  }
  ll temp = in[i] - i + 1;
  cur = temp / k;
  if (temp % k == 0) --cur;
  i++;
  ll now;
  for (; i <= m; i++) {
    in[i] -= i;
    now = in[i] / k;
    if (in[i] % k == 0) --now;
    if (now > cur) {
      ans++;
      cur = now;
    }
  }
  ans++;
  cout << ans << endl;
}
