Problem: A country called Flatland is an infinite two-dimensional plane. Flatland has n cities, each of them is a point on the plane.

Flatland is ruled by king Circle IV. Circle IV has 9 sons. He wants to give each of his sons part of Flatland to rule. For that, he wants to draw four distinct straight lines, such that two of them are parallel to the Ox axis, and two others are parallel to the Oy axis. At that, no straight line can go through any city. Thus, Flatland will be divided into 9 parts, and each son will be given exactly one of these parts. Circle IV thought a little, evaluated his sons' obedience and decided that the i-th son should get the part of Flatland that has exactly ai cities.

Help Circle find such four straight lines that if we divide Flatland into 9 parts by these lines, the resulting parts can be given to the sons so that son number i got the part of Flatland which contains ai cities.

Input

The first line contains integer n (9 ≤ n ≤ 105) — the number of cities in Flatland. Next n lines each contain two space-separated integers: xi, yi ( - 109 ≤ xi, yi ≤ 109) — the coordinates of the i-th city. No two cities are located at the same point. The last line contains nine space-separated integers: <image>.

Output

If there is no solution, print a single integer -1.

Otherwise, print in the first line two distinct real space-separated numbers: x1, x2 — the abscissas of the straight lines that are parallel to the Oy axis. And in the second line print two distinct real space-separated numbers: y1, y2 — the ordinates of the straight lines, parallel to the Ox. If there are multiple solutions, print any of them. 

When the answer is being checked, a city is considered to lie on a straight line, if the distance between the city and the line doesn't exceed 10 - 6. Two straight lines are considered the same if the distance between them doesn't exceed 10 - 6.

Examples

Input

9
1 1
1 2
1 3
2 1
2 2
2 3
3 1
3 2
3 3
1 1 1 1 1 1 1 1 1


Output

1.5000000000 2.5000000000
1.5000000000 2.5000000000


Input

15
4 4
-1 -3
1 5
3 -4
-4 4
-1 1
3 -3
-4 -5
-3 3
3 2
4 1
-4 2
-2 -5
-3 4
-1 4
2 1 2 1 2 1 3 2 1


Output

-3.5000000000 2.0000000000
3.5000000000 -1.0000000000


Input

10
-2 10
6 0
-16 -6
-4 13
-4 -2
-17 -10
9 15
18 16
-5 2
10 -5
2 1 1 1 1 1 1 1 1


Output

-1

Note

The solution for the first sample test is shown below:

<image>

The solution for the second sample test is shown below:

<image>

There is no solution for the third sample test.

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
int X[100010], Y[100010], SymX[100010], SymY[100010], tmp[100010], A[10], n,
    hsh[100010], Xx[100010], Yx[100010], T[100010], Tx[210][100010], cnt = 0;
bool cmpx(int x, int y) { return X[x] < X[y]; }
bool cmpy(int x, int y) { return Y[x] < Y[y]; }
int check(int x, int y, int goal) {
  if (Xx[x] == -1 || Yx[y] == -1) return 0;
  int s = hsh[x], v = Yx[y];
  for (int i = v; i; i -= i & (-i)) goal -= Tx[s][i];
  return goal == 0;
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d%d", &X[i], &Y[i]);
  for (int i = 1; i <= 9; i++) scanf("%d", &A[i]);
  sort(A + 1, A + 10);
  for (int i = 1; i <= 9; i++)
    for (int j = i + 1; j <= 9; j++)
      for (int k = j + 1; k <= 9; k++) {
        int tmp = A[i] + A[j] + A[k];
        if (!hsh[tmp]) hsh[tmp] = ++cnt;
        if (!hsh[n - tmp]) hsh[n - tmp] = ++cnt;
      }
  for (int i = 1; i <= n; i++) tmp[i] = i;
  sort(tmp + 1, tmp + n + 1, cmpy);
  for (int i = 1, t = 1; i <= n; i++) {
    SymY[t] = Y[tmp[i]];
    if (Y[tmp[i]] == Y[tmp[i + 1]])
      Yx[i] = -1, Y[tmp[i]] = t;
    else
      Yx[i] = t, Y[tmp[i]] = t++;
  }
  for (int i = 1; i <= n; i++) tmp[i] = i;
  sort(tmp + 1, tmp + n + 1, cmpx);
  for (int i = 1, t = 1; i <= n; i++) {
    SymX[t] = X[tmp[i]];
    if (X[tmp[i]] == X[tmp[i + 1]])
      Xx[i] = -1, X[tmp[i]] = t;
    else
      Xx[i] = t, X[tmp[i]] = t++;
  }
  for (int i = 1; i <= n; i++) {
    for (int j = Y[tmp[i]]; j <= n; j += j & (-j)) T[j]++;
    if (hsh[i] && Xx[i] != -1) memcpy(Tx[hsh[i]], T, sizeof T);
  }
  for (;;) {
    int a1 = A[1] + A[2] + A[3], a2 = a1 + A[4] + A[5] + A[6],
        a3 = A[1] + A[4] + A[7], a4 = a3 + A[2] + A[5] + A[8];
    if (check(a3, a1, A[1]) && check(a4, a1, A[1] + A[2]) &&
        check(a3, a2, A[1] + A[4]) && check(a4, a2, A[1] + A[2] + A[4] + A[5]))
      return printf("%.12lf %.12lf\n%.12lf %.12lf\n", SymX[Xx[a3]] + 0.5,
                    SymX[Xx[a4]] + 0.5, SymY[Yx[a1]] + 0.5, SymY[Yx[a2]] + 0.5),
             0;
    if (!next_permutation(A + 1, A + 10)) return puts("-1"), 0;
  }
}