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 JAVA):

Solution:
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.StreamTokenizer;
import java.util.Arrays;
import java.util.Comparator;

/**
 * Created by yaroslav.ovcharenko on 12/20/16.
 */

public class Main {
    static StreamTokenizer st = new StreamTokenizer(new BufferedReader(new InputStreamReader(System.in), 8192*8))  ;
    private static Point[] px;
    private static Point[] py;
    private static Fenwick[] fs;
    private static int n;
    private static int width;

    public static void main(String[] args) throws IOException {
        n = nextInt();
        px = new Point[n];
        py = new Point[n];
        int div = 100;
        width = n/div;
        if(width == 0) width = 1;
        fs = new Fenwick[n /width +  1];

        for (int i=0; i<n; i++) {
            Point point = new Point(nextInt(), nextInt());
            px[i] = point;
            py[i] = point;
        }
        int[] a = new int[9]       ;
        for (int i=0; i<9; i++) {
            a[i]=nextInt() ;
        }
        Arrays.sort(a);
        Arrays.sort(px, Comparator.comparing(p->p.x));
        Arrays.sort(py, Comparator.comparing(p->p.y));
        for (int ii=0; ii<n; ii++) {
            int i = ii / width;
            if(fs[i] == null) fs[i] = new Fenwick(n);
            int y = Arrays.binarySearch(py, px[ii], Comparator.comparing(p->p.y));
            fs[i].inc(y);
        }
        permute(a, 0);
        System.out.println(-1);
    }

    static String calb(int []p){
        int p0 = p[0];
        int p1 = p[1];
        int p2 = p[2];
        int p3 = p[3];
        int p4 = p[4];
        int p5 = p[5];
        int p6 = p[6];
        int p7 = p[7];
        int p8 = p[8];

        int left = p0 + p3 +  p6;
        int left2Middle = left + p1 + p4 + p7;
        int right = p2 + p5 + p8;


        Point pxl1 = px[(left - 1)];
        Point pxleft = px[left];
        Point pxlm1 = px[(left2Middle - 1)];
        Point pxlm = px[left2Middle];
        Point x1 = pxl1;
        Point x2 = pxlm1;
        if((px.length - left2Middle) != right) return null;
        if(pxleft.x == x1.x) return null;
        if(pxlm.x == x2.x) return null;
        int top = p0 + p1 + p2;
        int top2Middle = top + p3 + p4 + p5;
        Point pyt1 = py[(top - 1)];
        Point pyt = py[top];
        Point pytm1 = py[(top2Middle - 1)];
        Point pytm = py[top2Middle];
        Point y1 = pyt1;
        Point y2 = pytm1;
        int bottom = p6 + p7 + p8;
        if((py.length - top2Middle) != bottom)  return null;
        if(pyt.y == y1.y)  return null;
        if(pytm.y == y2.y)  return null;

        int s1 = fss(fs, left-1, top-1, width, px, py);
        if(s1 != p0)  return null;
        int s2 = fss(fs, left-1, top2Middle-1, width, px, py);
        if(s2 != p0+p3)  return null;
        int s4 = fss(fs, left2Middle-1, top-1, width, px, py);
        if(s4 != p0+p1)  return null;
        int s5 = fss(fs, left2Middle-1, top2Middle-1, width, px, py);
        if(s5 != p0+p1+p3+p4)  return null;

        return String.format("%.10f %.10f\n%.10f %.10f", x1.x + .5, x2.x + .5, y1.y + .5, y2.y + .5);
    }

    static int fss(Fenwick[] f, int x1, int y1, int width, Point[] px, Point[] py) {
        int x2 = x1+1;
        int sum = 0;
        int s = x2 - (x2/width)*width;
        int xf = s==0? x1 : 1 + x1 - s;
        int xt = x1;
        int i = s == 0? x1/width : x1/width-1;//?
        while (i >= 0) {
            sum += f[i].sum(y1);
            i--;
        }
        if(s!=0) {
            while (xf <= xt) {
                if (px[xf].y <= py[y1].y) sum++;
                xf++;
            }
        }
        return sum;
    }

    static void swap(int[] a, int index1, int index2) {
        int tmp = a[index1];
        a[index1] = a[index2];
        a[index2] = tmp;
    }

    static void permute(int[] arr, int k){
        if (k == arr.length -1){
            String r = calb(arr);
            if (r != null) {
                System.out.println(r);
                System.exit(0);
            }
        } else {
            int i = k;
            while(i < arr.length) {
                swap(arr, i, k);
                permute(arr, k+1);
                swap(arr, k, i);
                i++;
            }
        }
    }

    private static int nextInt() throws IOException {
        st.nextToken();
        return (int) st.nval;
    }
    private static class Point {
        int x;
        int y;

        public Point(int x, int y) {
            this.x = x;
            this.y = y;
        }
    }
    static class Fenwick {
        int[] t;
        int n;
        Fenwick(int n) {
            this.n = n;
            t = new int[n];
        }
        int sum (int x)
        {
            int result = 0;
            int i = x;
            while (i >= 0) {
                result += t[i];
                i = (i & i + 1) - 1;
            }
            return result;
        }

        void inc (int x)
        {
            int i = x;
            while (i < n) {
                t[i] += 1;
                i = i | i + 1;
            }
        }
    }
}