After being discouraged by 13 time-limit-exceeded verdicts on an ugly geometry problem, you decided to take a relaxing break for arts and crafts.

There is a piece of paper in the shape of a simple polygon with n vertices. The polygon may be non-convex, but we all know that proper origami paper has the property that any horizontal line intersects the boundary of the polygon in at most two points.

If you fold the paper along the vertical line x=f, what will be the area of the resulting shape? When you fold, the part of the paper to the left of the line is symmetrically reflected on the right side.

<image>

Your task is to answer q independent queries for values f_1,…,f_q.

Input

The first line contains two integers n, q (3≤ n≤ 10^5, 1≤ q≤ 10^5) — the number of polygon vertices and queries, respectively.

Each of the next n lines contains two integers x_i, y_i (|x_i|, |y_i|≤ 10^5) — the coordinates of the i-th point of the polygon. The polygon has an edge connecting each pair of adjacent points in the input, and also an edge between (x_1,y_1) and (x_n,y_n). It is guaranteed that the polygon is non-degenerate and that any horizontal line intersects the boundary of the polygon in at most two points. In particular, no boundary edge is strictly horizontal. Two adjacent sides may be collinear.

Each of the next q lines contains a single integer f_i (min_{j=1}^n(x_j)< f_i< max_{j=1}^n(x_j)) — the x-coordinate of the i-th fold query. It is guaranteed that all f_i are distinct.

Output

For each query, output the area A_i of the paper if you fold it along the line x=f_i.

Your answer is considered correct if its absolute or relative error does not exceed 10^{-4}.

Formally, let your answer be a, and the jury's answer be b. Your answer is accepted if and only if \frac{|a - b|}{max{(1, |b|)}} ≤ 10^{-4}.

Examples

Input


4 7
0 10
10 0
0 -10
-10 0
-9
-5
-1
0
1
5
9


Output


199.0000000000
175.0000000000
119.0000000000
100.0000000000
119.0000000000
175.0000000000
199.0000000000


Input


4 1
0 0
0 2
2 4
2 2
1


Output


3.0000000000


Input


9 4
0 -3
2 -2
-1 -1
0 4
2 5
1 6
-2 3
-1 1
-3 0
0
-2
-1
1


Output


11.1250000000
11.7500000000
10.3446969697
11.3333333333

Note

The first test, with the fold f=-5:

<image>

The second test, with the fold f=1:

<image>

The third test, with the fold f=-1:

<image>
#include <bits/stdc++.h>
using std::cin;
using std::cout;
const double eps = 1e-10;
const int N = 200054;
struct vec2 {
  double x, y;
  vec2(double x0 = 0.0, double y0 = 0.0) : x(x0), y(y0) {}
  inline friend std::istream &operator>>(std::istream &in, vec2 &B) {
    return in >> B.x >> B.y;
  }
  inline double operator^(const vec2 &B) const { return x * B.y - y * B.x; }
} poly[N], l[N], m[N], r[N];
struct sweepLine {
  double x, a, b, c;
  sweepLine() {}
  sweepLine(double x_, double a_, double b_, double c_)
      : x(x_), a(a_), b(b_), c(c_) {}
  inline bool operator<(const sweepLine &B) const { return x < B.x; }
} sl[2003731];
int n, q, L, M, R;
double ansL[N], ansR[N];
std::pair<double, int> qry[N];
inline double getX(const vec2 &P, const vec2 &Q, double y) {
  return ((Q.x - P.x) * y + (P ^ Q)) / (Q.y - P.y);
}
void sweepTo(int L, vec2 *l, int R, vec2 *r, double *ans) {
  int i, j, cnt = 0;
  double dx, dy, k, A = 0., B = 0., C = 0.;
  for (i = 1; i < L; ++i) {
    dx = l[i].x - l[i - 1].x, dy = l[i].y - l[i - 1].y;
    if (fabs(dx) < eps)
      dx = (l[i - 1].x + l[i].x) * .5,
      sl[cnt++] = sweepLine(dx, 0., dy, -dy * dx);
    else if (dx > 0)
      k = .5 * dy / dx,
      sl[cnt++] = sweepLine(l[i - 1].x, k, -2. * k * l[i - 1].x,
                            k * l[i - 1].x * l[i - 1].x),
      sl[cnt++] = sweepLine(l[i].x, -k, 2. * k * l[i].x, -k * l[i].x * l[i].x);
    else
      k = -.5 * dy / dx,
      sl[cnt++] = sweepLine(l[i].x, k, -2. * k * l[i].x, k * l[i].x * l[i].x),
      sl[cnt++] = sweepLine(l[i - 1].x, -k, 2. * k * l[i - 1].x,
                            -k * l[i - 1].x * l[i - 1].x);
  }
  for (i = 1; i < R; ++i) {
    dx = r[i].x - r[i - 1].x, dy = r[i].y - r[i - 1].y;
    if (fabs(dx) < eps)
      dx = (r[i - 1].x + r[i].x) * .5,
      sl[cnt++] = sweepLine(dx, 0., -dy, dy * dx);
    else if (dx > 0)
      k = .5 * dy / dx,
      sl[cnt++] = sweepLine(r[i - 1].x, -k, 2. * k * r[i - 1].x,
                            -k * r[i - 1].x * r[i - 1].x),
      sl[cnt++] = sweepLine(r[i].x, k, -2. * k * r[i].x, k * r[i].x * r[i].x);
    else
      k = -.5 * dy / dx,
      sl[cnt++] = sweepLine(r[i].x, -k, 2. * k * r[i].x, -k * r[i].x * r[i].x),
      sl[cnt++] = sweepLine(r[i - 1].x, k, -2. * k * r[i - 1].x,
                            k * r[i - 1].x * r[i - 1].x);
  }
  std::sort(sl, sl + cnt);
  for (j = i = 0; i < cnt; ++i) {
    for (; j < q && qry[j].first <= sl[i].x; ++j)
      ans[qry[j].second] = (A * qry[j].first + B) * qry[j].first + C;
    A += sl[i].a, B += sl[i].b, C += sl[i].c;
  }
  for (; j < q; ++j) ans[qry[j].second] = C;
}
int main() {
  int i, j;
  double x, A = 0;
  std::ios::sync_with_stdio(false), cin.tie(NULL);
  cin >> n >> q;
  for (i = 0; i < n; ++i) cin >> poly[i];
  for (j = 0, i = 1; i < n; ++i)
    if (poly[i].y < poly[j].y) j = i;
  std::rotate(poly, poly + j, poly + n), poly[n] = *poly;
  for (j = 0, i = 1; i < n; ++i)
    if (poly[i].y > poly[j].y) j = i;
  for (i = 0; i < n; ++i) A += poly[i] ^ poly[i + 1];
  if (A < 0) A = -A, std::reverse(poly + 1, poly + n), j = n - j;
  L = n - j + 1, std::reverse_copy(poly + j, poly + (n + 1), l), R = j + 1,
  memcpy(r, poly, R * sizeof(vec2)), A *= .5;
  m[M++] = *poly;
  for (i = j = 1; i < L || j < R;)
    if (j != R && i != L && l[i].y == r[j].y)
      m[M++] = vec2((l[i].x + r[j].x) * .5, l[i].y), ++i, ++j;
    else if (j == R || (i != L && l[i].y < r[j].y))
      m[M++] = vec2((l[i].x + getX(r[j - 1], r[j], l[i].y)) * .5, l[i].y), ++i;
    else
      m[M++] = vec2((getX(l[i - 1], l[i], r[j].y) + r[j].x) * .5, r[j].y), ++j;
  for (i = 0; i < q; ++i) cin >> x, qry[i] = std::pair<double, int>(x, i);
  std::sort(qry, qry + q), cout.precision(12), sweepTo(L, l, M, m, ansL),
      sweepTo(M, m, R, r, ansR);
  for (i = 0; i < q; ++i) cout << A - ansL[i] + ansR[i] << '\n';
  return 0;
}
