Alexandra has a paper strip with n numbers on it. Let's call them ai from left to right.

Now Alexandra wants to split it into some pieces (possibly 1). For each piece of strip, it must satisfy:

  * Each piece should contain at least l numbers.
  * The difference between the maximal and the minimal number on the piece should be at most s.



Please help Alexandra to find the minimal number of pieces meeting the condition above.

Input

The first line contains three space-separated integers n, s, l (1 ≤ n ≤ 105, 0 ≤ s ≤ 109, 1 ≤ l ≤ 105).

The second line contains n integers ai separated by spaces ( - 109 ≤ ai ≤ 109).

Output

Output the minimal number of strip pieces.

If there are no ways to split the strip, output -1.

Examples

Input

7 2 2
1 3 1 2 4 1 2


Output

3


Input

7 2 2
1 100 1 100 1 100 1


Output

-1

Note

For the first sample, we can split the strip into 3 pieces: [1, 3, 1], [2, 4], [1, 2].

For the second sample, we can't let 1 and 100 be on the same piece, so no solution exists.
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.Arrays;
import java.util.StringTokenizer;

public class P487B
{
	static int oo = Integer.MAX_VALUE/2;
	public static void main(String[] args)
	{
		FastScanner scan = new FastScanner();
		int n = scan.nextInt();
		int s = scan.nextInt();
		int L = scan.nextInt();
		int[] arr = new int[n];
		for (int i = 0; i < arr.length; i++)
			arr[i] = scan.nextInt();
		MinSparseTable minst = new MinSparseTable(arr);
		MaxSparseTable maxst = new MaxSparseTable(arr);
		
		int[] dp = new int[n];
		SegTree st = new SegTree(n);
		for (int i = n-1; i >= 0; i--)
		{
			dp[i] = oo;
			st.inc(i, i, oo);
			int a = i+L;
			if (a > n)
				continue;
			int lo = i, hi = n-1;
			while (lo < hi)
			{
				int mid = (lo+hi+1)/2;
				int max = maxst.rmq(i, mid);
				int min = minst.rmq(i, mid);
				if (max-min <= s)
					lo = mid;
				else
					hi = mid-1;
			}
			int b = lo+1;
			if (b == n)
			{
				dp[i] = 1;
				st.inc(i, i, -oo + dp[i]);
				continue;
			}
			if (a > b)
				continue;
			dp[i] = st.rmq(a, b)+1;
			st.inc(i, i, -oo + dp[i]);
		}
		System.out.println(dp[0] >= oo ? -1 : dp[0]);
	}
	static class MaxSparseTable
	{
		int[] arr;
		int[][] maxs;
		MaxSparseTable(int[] a)
		{
			arr = a;
			int n = a.length;
			maxs = new int[1+Integer.numberOfTrailingZeros(Integer.highestOneBit(n))][n];
			for (int i = 0; i < maxs.length; i++)
			{
				for (int j = 0; j < n; j++)
				{
					if (i == 0)
						maxs[i][j] = arr[j];
					else if (j + (1 << i) <= n)
						maxs[i][j] = Math.max(maxs[i-1][j], maxs[i-1][j + (1 << i-1)]);
				}
			}
		}
		int rmq(int a, int b) //0-based
		{
			int len = b-a+1;
			int pow = Integer.highestOneBit(len);
			int exp = Integer.numberOfTrailingZeros(pow);
			return Math.max(maxs[exp][a], maxs[exp][b+1-pow]);
		}
	}
	static class SegTree
	{
		int n;
		int[] lo, hi, min, max, delta;
		SegTree(int t)
		{
			n = t;
			lo = new int[4*n+1];
			hi = new int[4*n+1];
			min = new int[4*n+1];
			max = new int[4*n+1];
			delta = new int[4*n+1];
			init(1, 0, n-1);
		}
		SegTree(int[] arr)
		{
			this(arr.length);
			for (int i = 0; i < n; i++)
				inc(i, i, arr[i]);
		}
		void init(int n, int l, int r)
		{
			lo[n] = l;
			hi[n] = r;
			if (l == r)
				return;
			int m = (l+r)/2;
			init(2*n, l, m);
			init(2*n+1, m+1, r);
		}
		void prop(int t)
		{
			delta[2*t] += delta[t];
			delta[2*t+1] += delta[t];
			delta[t] = 0;
		}
		int rmq(int l, int r)
		{
			return rmq(1, l, r);
		}
		int rmq(int t, int l, int r)
		{
			if (r < lo[t] || hi[t] < l)
				return Integer.MAX_VALUE;
			if (l <= lo[t] && hi[t] <= r)
				return min[t] + delta[t];
			prop(t);
			int minL = rmq(2*t, l, r);
			int minR = rmq(2*t+1, l, r);
			update(t);
			return Math.min(minL, minR);
		}
		int rmaxq(int l, int r)
		{
			return rmaxq(1, l, r);
		}
		int rmaxq(int t, int l, int r)
		{
			if (r < lo[t] || hi[t] < l)
				return Integer.MIN_VALUE;
			if (l <= lo[t] && hi[t] <= r)
				return max[t] + delta[t];
			prop(t);
			int maxL = rmaxq(2*t, l, r);
			int maxR = rmaxq(2*t+1, l, r);
			update(t);
			return Math.max(maxL, maxR);
		}
		void inc(int l, int r, int v)
		{
			inc(1, l, r, v);
		}
		void inc(int t, int l, int r, int v)
		{
			if (r < lo[t] || hi[t] < l)
				return;
			if (l <= lo[t] && hi[t] <= r)
			{
				delta[t] += v;
				return;
			}
			prop(t);
			inc(2*t, l, r, v);
			inc(2*t+1, l, r, v);
			update(t);
		}
		void update(int t)
		{
			min[t] = Math.min(min[2*t] + delta[2*t], min[2*t+1] + delta[2*t+1]);
			max[t] = Math.max(max[2*t] + delta[2*t], max[2*t+1] + delta[2*t+1]);
		}
	}
	static class MinSparseTable
	{
		int[] arr;
		int[][] mins;
		MinSparseTable(int[] a)
		{
			arr = a;
			int n = a.length;
			mins = new int[1+Integer.numberOfTrailingZeros(Integer.highestOneBit(n))][n];
			for (int i = 0; i < mins.length; i++)
			{
				for (int j = 0; j < n; j++)
				{
					if (i == 0)
						mins[i][j] = arr[j];
					else if (j + (1 << i) <= n)
						mins[i][j] = Math.min(mins[i-1][j], mins[i-1][j + (1 << i-1)]);
				}
			}
		}
		int rmq(int a, int b) //0-based
		{
			int len = b-a+1;
			int pow = Integer.highestOneBit(len);
			int exp = Integer.numberOfTrailingZeros(pow);
			return Math.min(mins[exp][a], mins[exp][b+1-pow]);
		}
	}
	static class FastScanner
	{
		BufferedReader br;
		StringTokenizer st;

		public FastScanner()
		{
			try
			{
				br = new BufferedReader(new InputStreamReader(System.in));
				st = new StringTokenizer(br.readLine());
			} catch (Exception e)
			{
				e.printStackTrace();
			}
		}

		public String next()
		{
			if (st.hasMoreTokens())
				return st.nextToken();
			try
			{
				st = new StringTokenizer(br.readLine());
			} catch (Exception e)
			{
				e.printStackTrace();
			}
			return st.nextToken();
		}

		public int nextInt()
		{
			return Integer.parseInt(next());
		}

		public long nextLong()
		{
			return Long.parseLong(next());
		}

		public String nextLine()
		{
			String line = "";
			try
			{
				line = br.readLine();
			} catch (Exception e)
			{
				e.printStackTrace();
			}
			return line;
		}
	}
}
