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;
long long a[100005], b[100005];
const long long inf = 0x3f3f3f3f3f3f3f3f;
void read(long long &x) {
  char c;
  while (!isdigit(c = getchar()))
    ;
  x = 0;
  while (isdigit(c)) {
    x = x * 10 + c - '0';
    c = getchar();
  }
}
bool chkmax(long long &a, long long b) { return a < b ? a = b, 1 : 0; }
long long stk[100005], id[100005], tp;
long long f[100005], g[100005];
struct smt {
  long long mx, mx1;
  long long tag;
  long long ls, rs;
  smt *l, *r;
  smt(long long la, long long ra) {
    ls = la;
    rs = ra;
    mx = mx1 = -inf;
    tag = 0;
    if (ls == rs) {
      l = r = 0;
      return;
    }
    long long mid = (ls + rs) >> 1;
    l = new smt(ls, mid);
    r = new smt(mid + 1, rs);
  }
  void set(long long x, long long y) {
    chkmax(mx, y);
    chkmax(mx1, y);
    if (ls == rs) return;
    x <= l->rs ? l->set(x, y) : r->set(x, y);
  }
  void put_tag(long long x) {
    tag += x;
    mx1 += x;
  }
  void push_down() {
    if (tag) {
      l->put_tag(tag);
      r->put_tag(tag);
      tag = 0;
    }
  }
  void add(long long la, long long ra, long long w) {
    if (la <= ls && rs <= ra) {
      tag += w;
      mx1 += w;
      return;
    }
    push_down();
    if (la <= l->rs) l->add(la, ra, w);
    if (r->ls <= ra) r->add(la, ra, w);
    mx1 = max(l->mx1, r->mx1);
  }
  long long query(long long mxr, long long pmx, long long w) {
    if (mxr < ls) return -inf;
    if (ls == rs) return ls;
    push_down();
    if (pmx <= r->mx + w && l->mx1 <= r->mx + w) {
      long long ret = r->query(mxr, max(pmx, l->mx1), w);
      if (ret != -inf) return ret;
    }
    if (pmx <= l->mx + w) {
      long long ret = l->query(mxr, pmx, w);
      if (ret != -inf) return ret;
    }
    return -inf;
  }
};
smt *rt;
signed main() {
  long long n, k;
  read(n);
  read(k);
  for (long long i = 1; i < n; ++i) read(a[i]);
  for (long long i = 1; i <= n; ++i) read(b[i]);
  for (long long i = 1; i <= n; ++i) {
    f[i] = f[i - 1] + b[i - 1] - a[i - 1];
    g[i] = g[i - 1] + b[i] - a[i - 1];
  }
  rt = new smt(1, n);
  long long ans = 0;
  id[0] = n + 1;
  for (long long i = n; i; --i) {
    rt->set(i, g[i]);
    while (tp && stk[tp] >= f[i]) {
      if (tp > 1) {
        rt->add(id[tp - 1] - 1, n, stk[tp - 1] - stk[tp]);
      }
      --tp;
    }
    if (tp) {
      rt->add(id[tp] - 1, n, f[i] - stk[tp]);
    }
    stk[++tp] = f[i];
    id[tp] = i;
    long long l = 1, r = tp, mid;
    while (l <= r) {
      mid = (l + r) >> 1;
      if (f[i] - stk[mid] <= k)
        r = mid - 1;
      else
        l = mid + 1;
    }
    long long w = 0;
    chkmax(ans, rt->query(id[r] - 1, -inf, k) - i + 1);
  }
  printf("%lld\n", ans);
  return 0;
}