#include <bits/stdc++.h>
using namespace std;
map<int, int> mp;
int n, s, l;
int dat[111111];
int lef[111111];
int dp[111111];
deque<int> q;
queue<int> qh;
const int MAX = 99999999;
int main() {
  cin >> n >> s >> l;
  for (int i = 1; i <= n; ++i) cin >> dat[i];
  fill(dp + 1, dp + n + 1, MAX);
  int p1 = n;
  for (int i = n; i >= 1; --i) {
    for (; p1; --p1) {
      mp[dat[p1]]++;
      if (mp.rbegin()->first - mp.begin()->first > s) {
        lef[i] = p1;
        if (!--mp[dat[p1]]) mp.erase(dat[p1]);
        break;
      }
    }
    if (!--mp[dat[i]]) mp.erase(dat[i]);
  }
  for (int i = 0; i < l; ++i) qh.push(i);
  for (int i = l; i <= n; ++i) {
    qh.push(i);
    while (!q.empty() && dp[q.back()] >= dp[qh.front()]) q.pop_back();
    q.push_back(qh.front());
    qh.pop();
    while (!q.empty() && q.front() < lef[i]) q.pop_front();
    if (!q.empty() && dp[i] > dp[q.front()] + 1) dp[i] = dp[q.front()] + 1;
  }
  cout << (dp[n] != MAX ? dp[n] : -1) << endl;
  return 0;
}
