#include <bits/stdc++.h>
using namespace std;
long long n, m, k, x, y, sizx, z, sizy, enx, eny, ans, len, second,
    segmax[400100], segmin[400100], a[100100], beh[100100], fro[100100];
void bldmax(long long pos, long long bb, long long ee) {
  long long mid = (ee + bb) / 2, l = pos * 2, r = l + 1;
  if (ee - bb <= 1) {
    segmax[pos] = bb;
    return;
  }
  bldmax(l, bb, mid);
  bldmax(r, mid, ee);
  if (a[segmax[l]] >= a[segmax[r]])
    segmax[pos] = segmax[l];
  else
    segmax[pos] = segmax[r];
}
long long maxbegir(long long pos, long long bb, long long ee, long long bx,
                   long long ex) {
  long long mid = (ee + bb) / 2, l = pos * 2, r = l + 1;
  if (ee - bb == ex - bx) return segmax[pos];
  if (ex <= mid) return maxbegir(l, bb, mid, bx, ex);
  if (bx >= mid) return maxbegir(r, mid, ee, bx, ex);
  long long LL = maxbegir(l, bb, mid, bx, mid);
  long long rr = maxbegir(r, mid, ee, mid, ex);
  if (a[LL] >= a[rr])
    return LL;
  else
    return rr;
}
void bldmin(long long pos, long long bb, long long ee) {
  long long mid = (ee + bb) / 2, l = pos * 2, r = l + 1;
  if (ee - bb <= 1) {
    segmin[pos] = bb;
    return;
  }
  bldmin(l, bb, mid);
  bldmin(r, mid, ee);
  if (a[segmin[l]] <= a[segmin[r]])
    segmin[pos] = segmin[l];
  else
    segmin[pos] = segmin[r];
}
long long minbegir(long long pos, long long bb, long long ee, long long bx,
                   long long ex) {
  long long mid = (ee + bb) / 2, l = pos * 2, r = l + 1;
  if (ee - bb == ex - bx) return segmin[pos];
  if (ex <= mid) return minbegir(l, bb, mid, bx, ex);
  if (bx >= mid) return minbegir(r, mid, ee, bx, ex);
  long long LL = minbegir(l, bb, mid, bx, mid);
  long long rr = minbegir(r, mid, ee, mid, ex);
  if (a[LL] <= a[rr])
    return LL;
  else
    return rr;
}
long long bs(long long bb, long long ee, long long az) {
  long long mm = (bb + ee) / 2;
  if (ee - bb <= 1) return bb;
  if (a[maxbegir(1, 0, n, az, mm + 1)] - a[minbegir(1, 0, n, az, mm + 1)] <= k)
    return bs(mm, ee, az);
  else
    return bs(bb, mm, az);
}
long long bs1(long long bb, long long ee, long long ta) {
  long long mm = (bb + ee) / 2;
  if (ee - bb <= 1) return ee;
  if (a[maxbegir(1, 0, n, mm, ta)] - a[minbegir(1, 0, n, mm, ta)] > k)
    return bs1(mm, ee, ta);
  else
    return bs1(bb, mm, ta);
}
int main() {
  ios::sync_with_stdio(false), cin.tie(0), cout.tie(0);
  cin >> n >> k >> len;
  for (int i = 0; i < n; i++) cin >> a[i];
  bldmax(1, 0, n);
  bldmin(1, 0, n);
  ans = 1;
  enx = fro[0] = bs(0, n, 0);
  sizx = enx + 1;
  z = 0;
  if (sizx < len) return cout << -1, 0;
  while (enx != n - 1) {
    eny = fro[enx + 1] = bs(enx + 1, n, enx + 1);
    sizy = eny - enx;
    ans++;
    y = beh[eny] = bs1(-1, eny + 1, eny + 1);
    if (sizx + sizy + z < 2 * len) return cout << -1, 0;
    z = min(enx - bs1(-1, enx + 2, enx + 2) + 1, enx - x + 1 - len);
    x = max(x + len, y);
    enx = eny;
    sizx = enx - x + 1;
  }
  cout << ans;
  return 0;
}
