Manao is solving a problem with the following statement:

<image>

He came up with a solution that produces the correct answers but is too slow. You are given the pseudocode of his solution, where the function getAnswer calculates the answer to the problem:
    
    
      
    getAnswer(a[1..n], b[1..len], h)  
      answer = 0  
      for i = 1 to n-len+1  
        answer = answer + f(a[i..i+len-1], b, h, 1)  
      return answer  
      
    f(s[1..len], b[1..len], h, index)  
      if index = len+1 then  
        return 1  
      for i = 1 to len  
        if s[index] + b[i] >= h  
          mem = b[i]  
          b[i] = 0  
          res = f(s, b, h, index + 1)  
          b[i] = mem  
          if res > 0  
            return 1  
      return 0  
    

Your task is to help Manao optimize his algorithm.

Input

The first line contains space-separated integers n, len and h (1 ≤ len ≤ n ≤ 150000; 1 ≤ h ≤ 109). The second line contains len space-separated integers b1, b2, ..., blen (1 ≤ bi ≤ 109). The third line contains n space-separated integers a1, a2, ..., an (1 ≤ ai ≤ 109).

Output

Print a single number — the answer to Manao's problem.

Examples

Input

5 2 10
5 3
1 8 5 5 7


Output

2
#include <bits/stdc++.h>
inline int getint() {
  int x = 0, p = 1;
  char c = getchar();
  while (c <= 32) c = getchar();
  if (c == 45) p = -p, c = getchar();
  while (c > 32) x = x * 10 + c - 48, c = getchar();
  return x * p;
}
using namespace std;
const int N = 150000 + 10;
bool flag = true;
multiset<int> S;
multiset<int>::iterator it;
int n, len, m, sz = 1, res, to[N], a[N], b[N], dat[N << 2], tag[N << 2];
vector<int> ord, v;
void pd(int k) {
  if ((k * 2 + 2) < (N << 2) && tag[k] != 0) {
    dat[2 * k + 1] += tag[k];
    dat[2 * k + 2] += tag[k];
    tag[2 * k + 1] += tag[k];
    tag[2 * k + 2] += tag[k];
    tag[k] = 0;
  }
}
void fM2(int x, int l, int r, int k, int del) {
  pd(k);
  if (r - l == 1) {
    dat[k] = del;
    return;
  }
  int mid = (l + r) >> 1;
  if (x < mid)
    fM2(x, l, mid, 2 * k + 1, del);
  else
    fM2(x, mid, r, 2 * k + 2, del);
  dat[k] = min(dat[2 * k + 1], dat[2 * k + 2]);
}
void fM(int x, int y, int l, int r, int k, int del) {
  pd(k);
  if (r <= x || l >= y) return;
  if (x <= l && r <= y) {
    dat[k] += del;
    tag[k] += del;
    return;
  }
  fM(x, y, l, (l + r) >> 1, 2 * k + 1, del);
  fM(x, y, (l + r) >> 1, r, 2 * k + 2, del);
  dat[k] = min(dat[2 * k + 1], dat[2 * k + 2]);
}
int fQ(int x, int l, int r, int k) {
  pd(k);
  if (r - l == 1) return dat[k];
  int mid = (l + r) >> 1;
  if (x < mid)
    return fQ(x, l, mid, 2 * k + 1);
  else
    return fQ(x, mid, r, 2 * k + 2);
}
bool fQ() { return dat[0] >= 0; }
int main() {
  n = getint();
  len = getint();
  m = getint();
  for (int(i) = 0; (i) < (len); (i)++) b[i] = getint();
  sort(b, b + len);
  for (int(i) = 0; (i) < (n); (i)++) {
    a[i] = getint();
    ord.push_back(a[i]);
    if (i < len) v.push_back(a[i]);
  }
  sort(ord.begin(), ord.end());
  ord.resize(unique(ord.begin(), ord.end()) - ord.begin());
  for (int(i) = 0; (i) < (ord.size()); (i)++) {
    int x = m - ord[i], p = lower_bound(b, b + len, x) - b;
    to[i] = p;
  }
  while (sz < ord.size()) sz <<= 1;
  sort(v.begin(), v.end());
  reverse(v.begin(), v.end());
  fM(0, sz, 0, sz, 0, 1000000000);
  for (int(i) = 0; (i) < (len); (i)++) {
    if (v[i] + b[i] < m) {
      flag = false;
    }
    int x = lower_bound((ord).begin(), (ord.end()), v[i]) - ord.begin();
    if (S.find(x) == S.end()) {
      fM2(x, 0, sz, 0, i - to[x]);
    }
    S.insert(x);
  }
  if (fQ()) res++;
  for (int i = len; i < n; i++) {
    int x = lower_bound((ord).begin(), (ord.end()), a[i - len]) - ord.begin();
    int y = lower_bound((ord).begin(), (ord.end()), a[i]) - ord.begin();
    fM(0, x, 0, sz, 0, -1);
    S.erase(S.find(x));
    if (S.find(x) == S.end()) {
      fM2(x, 0, sz, 0, 1000000000);
    }
    fM(0, y, 0, sz, 0, 1);
    if (S.find(y) == S.end()) {
      it = S.upper_bound(y);
      int z;
      if (it != S.end()) {
        z = fQ(*it, 0, sz, 0) + to[*it] + 1;
      } else
        z = 0;
      fM2(y, 0, sz, 0, z - to[y]);
    }
    S.insert(y);
    if (fQ()) res++;
  }
  printf("%d\n", res);
  return 0;
}
