Problem: Kekoland is a country with n beautiful cities numbered from left to right and connected by n - 1 roads. The i-th road connects cities i and i + 1 and length of this road is wi kilometers. 

When you drive in Kekoland, each time you arrive in city i by car you immediately receive gi liters of gas. There is no other way to get gas in Kekoland.

You were hired by the Kekoland president Keko to organize the most beautiful race Kekoland has ever seen. Let race be between cities l and r (l ≤ r). Race will consist of two stages. On the first stage cars will go from city l to city r. After completing first stage, next day second stage will be held, now racers will go from r to l with their cars. Of course, as it is a race, racers drive directly from start city to finish city. It means that at the first stage they will go only right, and at the second stage they go only left. Beauty of the race between l and r is equal to r - l + 1 since racers will see r - l + 1 beautiful cities of Kekoland. Cars have infinite tank so racers will take all the gas given to them.

At the beginning of each stage racers start the race with empty tank (0 liters of gasoline). They will immediately take their gasoline in start cities (l for the first stage and r for the second stage) right after the race starts. 

It may not be possible to organize a race between l and r if cars will run out of gas before they reach finish.

You have k presents. Each time you give a present to city i its value gi increases by 1. You may distribute presents among cities in any way (also give many presents to one city, each time increasing gi by 1). What is the most beautiful race you can organize?

Each car consumes 1 liter of gas per one kilometer.

Input

The first line of the input contains two integers n and k (2 ≤ n ≤ 100 000, 0 ≤ k ≤ 109) — the number of cities in Kekoland and the number of presents you have, respectively.

Next line contains n - 1 integers. The i-th of them is wi (1 ≤ wi ≤ 109) — the length of the road between city i and i + 1. 

Next line contains n integers. The i-th of them is gi (0 ≤ gi ≤ 109) — the amount of gas you receive every time you enter city i.

Output

Print a single line — the beauty of the most beautiful race you can organize.

Examples

Input

4 4
2 2 2
1 1 1 1


Output

4


Input

8 5
2 2 2 3 7 3 1
1 3 1 5 4 0 2 5


Output

7

Note

In first sample if you give one present to each city then it will be possible to make a race between city 1 and city 4.

In second sample you should add 1 to g5 and 4 to g6, then it will be possible to make a race between cities 2 and 8. 

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
int n, k;
const int N = 300000;
const long long INF = 1e16;
long long wi[N], gi[N];
int tot;
int lb[N], rb[N], lc[N], rc[N];
long long suffix[N];
long long tag[N], max_s[N], min_g[N], max_c[N], min_c[N], min_f[N];
void modify2(int t, long long x) {
  tag[t] += x;
  max_c[t] += x;
  min_c[t] += x;
  max_s[t] += x;
  min_g[t] += x;
}
void psdw(int t) {
  modify2(lc[t], tag[t]);
  modify2(rc[t], tag[t]);
  tag[t] = 0;
}
long long query_g(int t, long long p_max_s) {
  if (lb[t] == rb[t]) return p_max_s + min_f[t];
  psdw(t);
  if (p_max_s <= max_s[lc[t]])
    return min(query_g(lc[t], p_max_s), min_g[t]);
  else
    return min(p_max_s + min_f[lc[t]], query_g(rc[t], p_max_s));
}
void upd(int t) {
  max_s[t] = max(max_s[lc[t]], max_s[rc[t]]);
  max_c[t] = max(max_c[lc[t]], max_c[rc[t]]);
  min_c[t] = min(min_c[lc[t]], min_c[rc[t]]);
  min_f[t] = min(min_f[lc[t]], min_f[rc[t]]);
  min_g[t] = query_g(rc[t], max_s[lc[t]]);
}
int build(int l, int r) {
  int t = ++tot;
  lb[t] = l;
  rb[t] = r;
  if (l < r) {
    lc[t] = build(l, (l + r) / 2);
    rc[t] = build((l + r) / 2 + 1, r);
    upd(t);
  } else
    max_s[t] = suffix[l], min_f[t] = -suffix[l];
  return t;
}
void modify1(int t, int x, long long d) {
  if (x <= lb[t])
    if (min_c[t] + d >= 0) {
      modify2(t, d);
      return;
    } else if (min_c[t] == max_c[t]) {
      modify2(t, -min_c[t]);
      return;
    }
  psdw(t);
  if (x <= rb[lc[t]]) modify1(lc[t], x, d);
  modify1(rc[t], x, d);
  upd(t);
}
int query1(int t, int l, int r, long long &p_max_s) {
  psdw(t);
  if (l > r) return 0;
  if (l <= lb[t] && rb[t] <= r) {
    int val;
    if (lb[t] == rb[t]) {
      val = p_max_s + min_f[t] <= k ? lb[t] : 0;
    } else if (p_max_s <= max_s[lc[t]]) {
      long long tmp = max(p_max_s, max_s[lc[t]]);
      val = min_g[t] <= k ? query1(rc[t], l, r, tmp)
                          : query1(lc[t], l, r, p_max_s);
    } else {
      long long ggg = p_max_s;
      int tmp = query1(rc[t], l, r, ggg);
      val = tmp ? tmp
                : (p_max_s + min_f[lc[t]] <= k ? query1(lc[t], l, r, p_max_s)
                                               : 0);
      p_max_s = max(p_max_s, ggg);
    }
    p_max_s = max(p_max_s, max_s[t]);
    return val;
  }
  if (r <= rb[lc[t]])
    return query1(lc[t], l, r, p_max_s);
  else if (l >= lb[rc[t]])
    return query1(rc[t], l, r, p_max_s);
  else {
    int tmp = query1(lc[t], l, r, p_max_s);
    return max(tmp, query1(rc[t], l, r, p_max_s));
  }
}
int query2(int t, int l) {
  if (min_c[t] > k) return 0;
  if (max_c[t] <= k) return rb[t];
  if (lb[t] == rb[t]) return 0;
  if (rb[t] < l) return 0;
  psdw(t);
  int tmp = query2(rc[t], l);
  return tmp ? tmp : (l <= rb[lc[t]] ? query2(lc[t], l) : 0);
}
void dfs(long long A[], int t) {
  if (lb[t] == rb[t]) {
    cout << A[t] << " ";
    cout.flush();
    return;
  }
  psdw(t);
  dfs(A, lc[t]);
  dfs(A, rc[t]);
}
int res;
int main() {
  ios ::sync_with_stdio(0);
  cin >> n >> k;
  for (int i = 1; i < n; ++i) cin >> wi[i];
  wi[n] = INF;
  for (int i = 1; i <= n; ++i) cin >> gi[i];
  for (int i = 1; i <= n; ++i) suffix[i] = suffix[i - 1] + gi[i] - wi[i - 1];
  build(1, n);
  for (int i = n; i >= 1; --i) {
    modify1(1, i, wi[i] - gi[i]);
    long long EMP = -INF;
    int r = max(i, min(query2(1, i) + 1, n));
    res = max(res, query1(1, i, r, EMP) - i + 1);
  }
  cout << res << endl;
}