Problem: We have an old building with n + 2 columns in a row. These columns support the ceiling. These columns are located in points with coordinates 0 = x0 < x1 < ... < xn < xn + 1. The leftmost and the rightmost columns are special, we will call them bearing, the other columns are ordinary. 

For each column we know its durability di. Let's consider an ordinary column with coordinate x. Let's assume that the coordinate of the closest to it column to the left (bearing or ordinary) is a and the coordinate of the closest to it column to the right (also, bearing or ordinary) is b. In this task let's assume that this column supports the segment of the ceiling from point <image> to point <image> (here both fractions are considered as real division). If the length of the segment of the ceiling supported by the column exceeds di, then the column cannot support it and it crashes after a while, and after that the load is being redistributeed between the neighbouring columns according to the same principle.

<image>

Thus, ordinary columns will be crashing for some time until the process stops at some state. One can prove that the set of the remaining columns doesn't depend on the order in which columns crash. If there are only two bearing columns left in the end, then we assume that the whole construction crashes under the weight of the roof. But if at least one ordinary column stays in addition to the bearing ones, then the building doesn't crash.

To make the building stronger, we can add one extra ordinary column of arbitrary durability d' at any (not necessarily integer) point 0 < x' < xn + 1. If point x' is already occupied by an ordinary column, it is replaced by a new one.

Your task is to find out: what minimal durability can the added column have so that the building doesn't crash?

Input

The first line contains integer n (1 ≤ n ≤ 105) — the number of ordinary columns.

The second line contains n + 2 integers x0, x1, ..., xn, xn + 1 (x0 = 0, xi < xi + 1 for 0 ≤ i ≤ n, xn + 1 ≤ 109) — the coordinates of the columns.

The third line contains n integers d1, d2, ..., dn (1 ≤ di ≤ 109).

Output

Print a single number — the minimum possible durability of the column that you need to add in order to make the building stay. If you do not have to add the column, please print 0. Your answer will be checked with the relative or absolute error 10 - 4.

Examples

Input

2
0 20 40 100
15 40


Output

10


Input

3
0 4 10 28 30
9 13 5


Output

0

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
template <typename T>
bool ckmax(T &x, T y) {
  return x < y ? x = y, true : false;
}
template <typename T>
bool ckmin(T &x, T y) {
  return x > y ? x = y, true : false;
}
using namespace std;
const long long inf = 1000000000;
const double Pi = acos(-1);
const long long mod = 1e9 + 81;
const double eps = 1e-6;
inline long long fpow(long long a, long long b = mod - 2, long long p = mod) {
  a %= p;
  long long res = 1;
  while (b) {
    if (b & 1) res = 1ll * res * a % p;
    a = 1ll * a * a % p;
    b >>= 1;
  }
  return res;
}
inline long long read() {
  char c = getchar();
  long long x = 0;
  bool f = 0;
  for (; !isdigit(c); c = getchar()) f ^= !(c ^ 45);
  for (; isdigit(c); c = getchar()) x = (x << 1) + (x << 3) + (c ^ 48);
  if (f) x = -x;
  return x;
}
inline void write(long long x) {
  if (x < 0) {
    putchar('-');
    write(-x);
    return;
  }
  if (x >= 10) write(x / 10);
  putchar(x % 10 + '0');
}
inline void writesp(long long x) { write(x), putchar(' '); }
inline void writeln(long long x) {
  write(x);
  putchar('\n');
}
long long n;
long long x[111111], d[111111];
long long stk[111111], top;
long long L[111111], R[111111];
inline long long check(long long r, long long v) {
  long long l = 0;
  while (r - l >= 10) {
    long long mid = (l + r) >> 1;
    if (2 * d[stk[mid]] + L[stk[mid]] >= v)
      l = mid + 1;
    else
      r = mid - 1;
  }
  for (long long i = (r), iE = (l); i >= iE; i--)
    if (2 * d[stk[i]] + L[stk[i]] >= v) return i;
}
signed main() {
  n = read();
  for (long long i = (0), iE = (n + 1); i <= iE; i++) x[i] = read();
  for (long long i = (1), iE = (n); i <= iE; i++) d[i] = read();
  d[0] = d[n + 1] = inf;
  for (long long i = (1), iE = (n + 1); i <= iE; i++) {
    while (top && 2 * d[stk[top]] + L[stk[top]] < x[i]) --top;
    L[i] = x[stk[top]];
    stk[++top] = i;
  }
  if (top > 1) return puts("0") & 0;
  stk[top = 0] = n + 1;
  for (long long i = (n), iE = (1); i >= iE; i--) {
    while (top && R[stk[top]] - 2 * d[stk[top]] > x[i]) --top;
    R[i] = x[stk[top]];
    stk[++top] = i;
  }
  stk[top = 0] = 0;
  long long ans = 1e10;
  for (long long i = (1), iE = (n + 1); i <= iE; i++) {
    if (x[i] > R[i] - 2 * d[i]) {
      long long j = check(top, R[i] - 2 * d[i]);
      assert(i >= stk[j]);
      ckmin(ans, x[i] - x[stk[j]]);
    }
    if (x[i] >= 2 * d[i] + L[i]) continue;
    while (top && 2 * d[i] + L[i] >= 2 * d[stk[top]] + L[stk[top]]) --top;
    stk[++top] = i;
  }
  printf("%.12lf\n", ans / 2.0);
}