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;
bool debug = 0;
int n, m, k;
int dx[4] = {0, 1, 0, -1}, dy[4] = {1, 0, -1, 0};
string direc = "RDLU";
long long ln, lk, lm;
void etp(bool f = 0) {
  puts(f ? "Possible" : "Impossible");
  exit(0);
}
void addmod(int &x, int y, int mod = 1000000007) {
  x += y;
  if (x >= mod) x -= mod;
}
void et() {
  puts("-1");
  exit(0);
}
vector<int> mp[100055];
int w[100055], g[100055], nxt[100055], ans;
long long pre[100055], suf[100055];
struct lctree {
  long long T[100055 * 4], lz[100055 * 4];
  long long mp[100055 * 4], ms[100055 * 4];
  void add(int rt, long long val) {
    T[rt] += val;
    lz[rt] += val;
    ms[rt] += val;
  }
  long long calc(int rt, int l, int r, long long leftMax) {
    if (l == r) return leftMax + mp[rt];
    down(rt, l, r);
    int mid = (l + r) / 2;
    if (leftMax <= ms[(rt << 1)])
      return min(T[rt], calc((rt << 1), l, mid, leftMax));
    else
      return min(mp[(rt << 1)] + leftMax,
                 calc((rt << 1 | 1), mid + 1, r, leftMax));
  }
  void up(int rt, int l, int r) {
    ms[rt] = max(ms[(rt << 1)], ms[(rt << 1 | 1)]);
    int mid = (l + r) / 2;
    T[rt] = calc((rt << 1 | 1), mid + 1, r, ms[(rt << 1)]);
  }
  void down(int rt, int l, int r) {
    if (lz[rt]) {
      if (l + 1 <= r) {
        add((rt << 1), lz[rt]);
        add((rt << 1 | 1), lz[rt]);
      }
      lz[rt] = 0;
    }
  }
  void build(int rt, int l, int r) {
    if (l == r) {
      mp[rt] = -suf[r];
      ms[rt] = suf[r];
      return;
    }
    int mid = (l + r) / 2;
    build((rt << 1), l, mid);
    build((rt << 1 | 1), mid + 1, r);
    mp[rt] = min(mp[(rt << 1)], mp[(rt << 1 | 1)]);
    up(rt, l, r);
  }
  void upt(int rt, int l, int r, int L, int R, long long val) {
    if (r < L || R < l) return;
    if (L <= l && r <= R) {
      add(rt, val);
      return;
    }
    down(rt, l, r);
    int mid = (l + r) / 2;
    upt((rt << 1), l, mid, L, R, val);
    upt((rt << 1 | 1), mid + 1, r, L, R, val);
    up(rt, l, r);
  }
  int qyb(int rt, int l, int r, long long val, long long K) {
    if (l == r) return val + mp[rt] <= K ? l : 0;
    down(rt, l, r);
    int mid = (l + r) / 2;
    long long tmp =
        val <= ms[(rt << 1)] ? T[rt] : calc((rt << 1 | 1), mid + 1, r, val);
    if (tmp <= K)
      return qyb((rt << 1 | 1), mid + 1, r, max(val, ms[(rt << 1)]), K);
    return qyb((rt << 1), l, mid, val, K);
  }
} mb;
vector<int> roots;
void dfs(int x, int pa) {
  roots.push_back(x);
  if (x != n + 1) {
    int l = 0, r = roots.size();
    while (l + 1 < r) {
      int mid = (l + r) / 2;
      if (pre[x - 1] - pre[roots[mid] - 1] <= k)
        r = mid;
      else
        l = mid;
    }
    if (x > 1) mb.upt(1, 1, n, 1, x - 1, -(1LL << 60));
    if (roots[l] <= n) mb.upt(1, 1, n, roots[l], n, (1LL << 60));
    ans = max(ans, mb.qyb(1, 1, n, -(1LL << 60), k) - x + 1);
    if (x > 1) mb.upt(1, 1, n, 1, x - 1, (1LL << 60));
    if (roots[l] <= n) mb.upt(1, 1, n, roots[l], n, -(1LL << 60));
  }
  for (int c : mp[x])
    if (c != pa) {
      if (x != n + 1) {
        long long tmp = pre[c - 1] - pre[x - 1];
        assert(tmp > 0);
        mb.upt(1, 1, n, x - 1, n, tmp);
        dfs(c, x);
        mb.upt(1, 1, n, x - 1, n, -tmp);
      } else
        dfs(c, x);
    }
  roots.pop_back();
}
void fmain() {
  scanf("%d%d", &n, &k);
  for (int(i) = 1; (i) <= (int)(n - 1); (i)++) scanf("%d", w + i);
  for (int(i) = 1; (i) <= (int)(n); (i)++) scanf("%d", g + i);
  for (int(i) = 1; (i) <= (int)(n); (i)++) {
    pre[i] = pre[i - 1] + g[i] - w[i];
    suf[i] = suf[i - 1] + g[i] - w[i - 1];
    nxt[i] = i;
  }
  for (int i = n; i; i--) {
    while (nxt[i] < n && pre[nxt[i]] - pre[i - 1] >= 0)
      nxt[i] = nxt[nxt[i] + 1];
    mp[nxt[i] + 1].push_back(i);
  }
  mb.build(1, 1, n);
  dfs(n + 1, 0);
  printf("%d\n", ans);
}
int main() {
  fmain();
  return 0;
}