#include <bits/stdc++.h>
using namespace std;
inline void File() {}
template <typename T>
inline void read(T &_) {
  _ = 0;
  T __ = getchar(), ___ = 1;
  while (!isdigit(__)) {
    if (__ == '-') ___ = -1;
    __ = getchar();
  }
  while (isdigit(__)) {
    _ = (_ << 1) + (_ << 3) + (__ ^ '0');
    __ = getchar();
  }
  _ *= ___;
}
template <typename T>
inline bool Chkmax(T &_, T __) {
  return _ < __ ? _ = __, 1 : 0;
}
template <typename T>
inline bool Chkmin(T &_, T __) {
  return _ > __ ? _ = __, 1 : 0;
}
const int N = 1e5 + 1e2;
int n, s, L;
int a[N], dp[N], Min[N][20], Max[N][20];
inline void Init() {
  for (int i = 1; i <= 19; i++)
    for (int j = 1; j <= n && j + (1 << i) - 1 <= n; j++) {
      Max[j][i] = max(Max[j][i - 1], Max[j + (1 << (i - 1))][i - 1]);
      Min[j][i] = min(Min[j][i - 1], Min[j + (1 << (i - 1))][i - 1]);
    }
}
inline int MIN(int l, int r) {
  int k = log2(r - l + 1);
  return min(Min[l][k], Min[r - (1 << k) + 1][k]);
}
inline int MAX(int l, int r) {
  int k = log2(r - l + 1);
  return max(Max[l][k], Max[r - (1 << k) + 1][k]);
}
struct Segment_Tree {
  int Emm[N << 2];
  inline void push_up(int rt) { Emm[rt] = min(Emm[rt << 1], Emm[rt << 1 | 1]); }
  inline void Update(int rt, int l, int r, int pos, int x) {
    if (l == r) {
      Emm[rt] = x;
      return;
    }
    int Mid = (l + r) >> 1;
    if (pos <= Mid) Update(rt << 1, l, Mid, pos, x);
    if (pos > Mid) Update(rt << 1 | 1, Mid + 1, r, pos, x);
    push_up(rt);
  }
  inline int query(int rt, int l, int r, int LL, int R) {
    if (LL <= l && r <= R) return Emm[rt];
    int Mid = (l + r) >> 1, tp = 0x3f3f3f3f;
    if (LL <= Mid) Chkmin(tp, query(rt << 1, l, Mid, LL, R));
    if (R > Mid) Chkmin(tp, query(rt << 1 | 1, Mid + 1, r, LL, R));
    return tp;
  }
} T;
int main() {
  File();
  read(n), read(s), read(L);
  for (int i = 1; i <= n; i++) read(a[i]), Max[i][0] = Min[i][0] = a[i];
  Init();
  for (int i = 1; i <= n; i++) {
    int l = 1, r = i - L + 1, Ans = -1;
    while (l <= r) {
      int Mid = (l + r) >> 1;
      if (MAX(Mid, i) - MIN(Mid, i) > s)
        l = Mid + 1;
      else
        Ans = Mid, r = Mid - 1;
    }
    if (Ans == -1) {
      dp[i + 1] = 0x3f3f3f3f;
      T.Update(1, 1, n, i + 1, dp[i + 1]);
      continue;
    }
    dp[i + 1] = T.query(1, 1, n, Ans, i - L + 1) + 1;
    T.Update(1, 1, n, i + 1, dp[i + 1]);
  }
  printf("%d\n", dp[n + 1] >= 0x3f3f3f3f ? -1 : dp[n + 1]);
  return 0;
}
