#include <bits/stdc++.h>
using namespace std;
set<pair<int, int>> p, q;
int a[100050], dp[100050], n, s, l;
int main() {
  int i, j, k;
  scanf("%d %d %d", &n, &s, &l);
  p.clear();
  q.clear();
  memset(dp, 0, sizeof(dp));
  for (i = 1; i <= n; i++) scanf("%d", &a[i]);
  for (i = 1, j = 0, k = 1; i <= n; i++) {
    p.insert(make_pair(a[i], i));
    while (p.rbegin()->first - p.begin()->first > s) {
      q.erase(make_pair(dp[j], j));
      p.erase(make_pair(a[k], k));
      j++, k++;
    }
    if (p.size() >= l) {
      if (dp[i - l] >= 0) q.insert(make_pair(dp[i - l], i - l));
    }
    if (q.size() > 0) {
      dp[i] = q.begin()->first + 1;
    } else
      dp[i] = -1;
  }
  printf("%d\n", dp[n]);
  return 0;
}
