#include <bits/stdc++.h>
using namespace std;
const long long INF = 1e12;
const int MX = 3 * 1e5 + 10;
const double PI = acos(-1.0), EPS = 1e-9;
int N, l, x;
int arr[MX];
pair<int, int> dp[MX][30];
pair<int, int> Q(int l, int r) {
  if (l > r) swap(l, r);
  int len = r - l + 1;
  int k = log2(len);
  return make_pair(min(dp[l][k].first, dp[l + len - (1 << k)][k].first),
                   max(dp[l][k].second, dp[l + len - (1 << k)][k].second));
}
long long dp1[MX], dp2[MX], st[MX * 4];
void update(int L, int R, int p, int i, int j, long long val) {
  if (L > R || L > j || R < i) return;
  if (L >= i && R <= j) {
    st[p] = val;
    return;
  }
  int mid = (L + R) / 2;
  update(L, mid, p * 2, i, j, val);
  update(mid + 1, R, p * 2 + 1, i, j, val);
  st[p] = min(st[p * 2], st[p * 2 + 1]);
}
long long query(int L, int R, int p, int i, int j) {
  if (L > R || L > j || R < i) return 1e17;
  if (L >= i && R <= j) return st[p];
  int mid = (L + R) / 2;
  return min(query(L, mid, p * 2, i, j), query(mid + 1, R, p * 2 + 1, i, j));
}
int main() {
  scanf("%d%d%d", &N, &x, &l);
  for (int i = 0; i < N; i++) scanf("%d", &arr[i]);
  for (int i = 0; i < N; i++) dp[i][0].first = dp[i][0].second = arr[i];
  for (int j = 1; (1 << j) <= N; j++) {
    for (int i = 0; i + (1 << j) <= N; i++) {
      dp[i][j].first =
          min(dp[i][j - 1].first, dp[i + (1 << (j - 1))][j - 1].first);
      dp[i][j].second =
          max(dp[i][j - 1].second, dp[i + (1 << (j - 1))][j - 1].second);
    }
  }
  for (int i = 0; i < N; i++) {
    dp2[i] = 2e9;
    int lo = 0, hi = i, mid;
    while (lo <= hi) {
      mid = (lo + hi) / 2;
      if (Q(mid, i).second - Q(mid, i).first <= x)
        dp1[i] = i - mid, hi = mid - 1;
      else
        lo = mid + 1;
    }
  }
  for (int i = 0; i < N; i++) {
    if (dp1[i] + 1 < l) {
      dp2[i] = INF;
    } else if (dp1[i] + 1 >= l && dp1[i] == i) {
      dp2[i] = 1;
    } else {
      int L = i - dp1[i] - 1, R = i - l;
      if (L > R) {
        dp2[i] = INF;
      } else {
        dp2[i] = query(0, N - 1, 1, L, R) + 1;
      }
    }
    update(0, N - 1, 1, i, i, dp2[i]);
  }
  if (dp2[N - 1] >= 1e6) dp2[N - 1] = -1;
  cout << dp2[N - 1] << "\n";
  return 0;
}
