#include <bits/stdc++.h>
using namespace std;
int getint() {
  char ch = getchar();
  for (; (ch < '0' || ch > '9') && (ch != '-'); ch = getchar())
    ;
  int tmp = 0;
  int d = 1;
  if (ch == '-') d = -1, ch = getchar();
  for (; ch >= '0' && ch <= '9'; ch = getchar()) tmp = tmp * 10 + ch - 48;
  return tmp * d;
}
const int maxn = 100000 + 10, oo = 1 << 29;
int N, L, S, Tree[maxn * 4];
int A[maxn], F[maxn];
multiset<int> Q;
void maketree(int w, int le, int ri) {
  Tree[w] = oo;
  if (le == ri) return;
  int mid = (le + ri) >> 1;
  maketree(w << 1, le, mid);
  maketree(w << 1 | 1, mid + 1, ri);
}
void modify(int w, int le, int ri, int &x, int &z) {
  if (le > x || ri < x) return;
  if (le == ri) {
    Tree[w] = z;
    return;
  }
  int mid = (le + ri) >> 1;
  modify(w << 1, le, mid, x, z);
  modify(w << 1 | 1, mid + 1, ri, x, z);
  Tree[w] = min(Tree[w << 1], Tree[w << 1 | 1]);
}
int query(int w, int le, int ri, int &x, int &y) {
  if (x > ri || y < le) return oo;
  if (x <= le && ri <= y) return Tree[w];
  int mid = (le + ri) >> 1;
  int p = query(w << 1, le, mid, x, y);
  int q = query(w << 1 | 1, mid + 1, ri, x, y);
  return min(p, q);
}
int main() {
  for (; scanf("%d%d%d", &N, &S, &L) != EOF;) {
    for (int i = (1), _i = (N); i <= _i; i++) A[i] = getint();
    maketree(1, 1, N);
    Q.clear();
    for (int j = (1), _j = (L - 1); j <= _j; j++) F[j] = oo, Q.insert(A[j]);
    F[0] = 0;
    int j = 1;
    for (int i = (L), _i = (N); i <= _i; i++) {
      Q.insert(A[i]);
      for (; (*Q.rbegin()) - (*Q.begin()) > S; j++) {
        multiset<int>::iterator iter;
        iter = Q.find(A[j]);
        Q.erase(iter);
      }
      if (i - j + 1 >= L) {
        int x = j - 1, y = i - L;
        if (x == 0)
          F[i] = 1;
        else
          F[i] = query(1, 1, N, x, y) + 1;
        if (F[i] > oo) F[i] = oo;
        if (F[i] != oo) modify(1, 1, N, i, F[i]);
      } else
        F[i] = oo;
    }
    if (F[N] != oo)
      printf("%d\n", F[N]);
    else
      printf("-1\n");
  }
  return 0;
}
