#include <bits/stdc++.h>
using namespace std;
const int N=5e5;

  int n,c,k;
  int a[N];
void in()
{
  cin>>n>>c>>k;
  for (int i=0;++i<=n;)
    scanf("%d",a+i);
}

  int A,t,e;
void wor()
{
  sort(a+1,a+n+1);
  for (int i=0;++i<=n;)
    {
      if (a[i]>e||t==c)
        ++A,t=0,e=a[i]+k;
      ++t;
    }
}

void out()
{
  cout<<A;
}

int main()
{
  in();
  wor();
  out();
  exit(0);
}