#include <bits/stdc++.h>
using namespace std;
const int M = 1e5;
const int INF = 1e9 + 5;
struct ST {
  int x, y;
};
vector<int> tree[(M << 2) + 5];
int req[10], n, se[10], x[M], y[M];
ST city[M];
bool cmp(const ST &a, const ST &b) { return a.x < b.x; }
void build_tree(int l, int r, int rt) {
  for (int i = l; i <= r; i++) {
    tree[rt].push_back(city[i].y);
  }
  sort(tree[rt].begin(), tree[rt].end());
  if (l == r) {
    return;
  }
  int mid = (l + r) >> 1;
  build_tree(l, mid, rt << 1);
  build_tree(mid + 1, r, rt << 1 | 1);
  return;
}
int Query(int l, int r, int L, int R, int ny, int rt) {
  if (l >= L && r <= R) {
    return upper_bound(tree[rt].begin(), tree[rt].end(), ny) - tree[rt].begin();
  }
  int mid = (l + r) >> 1, ans = 0;
  if (mid >= L) {
    ans += Query(l, mid, L, R, ny, rt << 1);
  }
  if (mid < R) {
    ans += Query(mid + 1, r, L, R, ny, rt << 1 | 1);
  }
  return ans;
}
bool judge() {
  int x1 = req[se[0]] + req[se[1]] + req[se[2]] - 1;
  int x2 = x1 + req[se[3]] + req[se[4]] + req[se[5]];
  int y1 = req[se[0]] + req[se[3]] + req[se[6]] - 1;
  int y2 = y1 + req[se[1]] + req[se[4]] + req[se[7]];
  if (x1 + 1 >= n || x[x1] == x[x1 + 1]) {
    return false;
  }
  if (x2 + 1 >= n || x[x2] == x[x2 + 1]) {
    return false;
  }
  if (y1 + 1 >= n || y[y1] == y[y1 + 1]) {
    return false;
  }
  if (y2 + 1 >= n || y[y2] == y[y2 + 1]) {
    return false;
  }
  if (Query(0, n - 1, 0, x1, y[y1], 1) != req[se[0]]) {
    return false;
  }
  if (Query(0, n - 1, 0, x1, y[y2], 1) != req[se[0]] + req[se[1]]) {
    return false;
  }
  if (Query(0, n - 1, x1 + 1, x2, y[y1], 1) != req[se[3]]) {
    return false;
  }
  if (Query(0, n - 1, x1 + 1, x2, y[y2], 1) != req[se[3]] + req[se[4]]) {
    return false;
  }
  double ansx1 = (x[x1] + x[x1 + 1]) / 2.0, ansx2 = (x[x2] + x[x2 + 1]) / 2.0;
  double ansy1 = (y[y1] + y[y1 + 1]) / 2.0, ansy2 = (y[y2] + y[y2 + 1]) / 2.0;
  printf("%.10lf %.10lf\n%.10lf %.10lf\n", ansx1, ansx2, ansy1, ansy2);
  return true;
}
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) {
    scanf("%d%d", &x[i], &y[i]);
    city[i].x = x[i];
    city[i].y = y[i];
  }
  sort(city, city + n, cmp);
  sort(x, x + n);
  sort(y, y + n);
  build_tree(0, n - 1, 1);
  for (int i = 0; i < 9; i++) {
    scanf("%d", &req[i]);
    se[i] = i;
  }
  int m = 362880;
  while (m--) {
    if (judge()) {
      return 0;
    }
    next_permutation(se, se + 9);
  }
  printf("-1\n");
  return 0;
}
