import 'dart:convert';
import 'dart:io';
import 'dart:async';

Future main() async {
  List nck = stdin.readLineSync().split(" ").map((x) => int.parse(x)).toList();
  Stream<String> tLines =
      stdin.transform(utf8.decoder).transform(LineSplitter()); // ここ大事（複数行入力）

  int ti;
  List ab = [];
  List abi = [];
  List limits = [];
  int limit0 = 0;
  int limit1 = 0;
  List tList0 = [];
  int lineNum;
  lineNum = 1;
  await for (String line in tLines) {
    lineNum = lineNum + 1;
    ti = int.parse(line);
    tList0.add(ti);
    limits.add(ti + nck[2]);

    if (lineNum > nck[0]) break; // ここの場所！
  }
  List tList = tList0..sort((a, b) => a.compareTo(b));

  int start = tList[0];
  // print(tList);
  int count = 1;

  int numb = 1;
  print(tList);
  for (int j = 0; j < nck[0] - 1; j++) {
    if (tList[j + 1] == tList[j]) {
      if (numb < nck[1]) {
        //  print("case2$j");
        //  print("numb$numb");

        //  print("count$count");
        numb++;
        continue;
      } else if (tList[j + 1] - start > nck[2] || numb >= nck[1]) {
        //  print("case3$j");
        //  print("numb$numb");

        numb = 1;
        count++;
        // print("count$count");
        start = tList[j];
        continue;
      }
    }

    if (tList[j + 1] - start > tList[j] || numb >= nck[1]) {
      //  print("case4$j");
      //  print("numb$numb");
      numb = 1;
      count++;

      // print("count$count");
      start = tList[j];
      // print("j$j");
    } else {
      //  print("case5$j");
      //  print("numb$numb");
      //        print("count$count");
      numb++;
    }
  }
  print(count);
}