#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 20, inf = 1e9 + 7;
int n, s, l, ar[maxn], dp[maxn], g[maxn];
struct sli {
  deque<pair<int, int>> data;
  void pushmx(int val, int id) {
    while (!data.empty() && data.back().first <= val) data.pop_back();
    data.push_back({val, id});
  }
  void pushmn(int val, int id) {
    while (!data.empty() && data.back().first >= val) data.pop_back();
    data.push_back({val, id});
  }
  void del(int id) {
    if (data.front().second == id) data.pop_front();
  }
} mn, mx;
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  cin >> n >> s >> l;
  for (int i = 1; i <= n; i++) cin >> ar[i];
  int j = 1, j2;
  for (int i = 1; i <= n; i++) {
    mx.pushmx(ar[i], i), mn.pushmn(ar[i], i);
    while (mx.data.front().first - mn.data.front().first > s)
      mn.del(j), mx.del(j), j++;
    g[i] = j;
  }
  mn.data.clear();
  j = 0, j2 = 1;
  mn.pushmn(dp[0] = 0, 0);
  for (int i = 1; i <= n; i++) {
    while (j2 <= i - l) mn.pushmn(dp[j2], j2), j2++;
    while (j < min(g[i] - 1, i - l)) mn.del(j), j++;
    dp[i] = mn.data.front().first + 1;
    if (i - g[i] + 1 < l) dp[i] = inf;
  }
  if (dp[n] >= inf) dp[n] = -1;
  cout << dp[n] << endl;
}
