#include <bits/stdc++.h>
using namespace std;
const int maxn = 100010;
const int INF = 1e9 + 7;
int n, s, l, dp[maxn], a[maxn];
multiset<int> st, v;
int main() {
  cin >> n >> s >> l;
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  for (int i = 1, j = 1; i <= n; i++) {
    st.insert(a[i]);
    while (*st.rbegin() - *st.begin() > s) {
      st.erase(st.find(a[j]));
      if (i - j >= l) {
        v.erase(v.find(dp[j - 1]));
      }
      j++;
    }
    if (i - j + 1 >= l) v.insert(dp[i - l]);
    if (v.begin() == v.end())
      dp[i] = INF;
    else
      dp[i] = *v.begin() + 1;
  }
  if (dp[n] >= INF)
    cout << -1 << endl;
  else
    cout << dp[n] << endl;
  return 0;
}
