#include <bits/stdc++.h>
using namespace std;
const int MAXN = 1e5 + 5;
int a[MAXN], b[MAXN];
int n, m;
int max1[5];
int min1[5];
int cst[4][2] = {{1, 1}, {1, 0}, {0, 1}, {0, 0}};
int main() {
  scanf("%d%d", &n, &m);
  int c;
  scanf("%d", &c);
  for (int i = 0; i < 4; i++) {
    min1[i] = INT_MAX;
    max1[i] = -INT_MAX;
  }
  for (int i = 1; i <= c; i++) {
    int x[2];
    scanf("%d%d", &x[0], &x[1]);
    for (int i = 0; i < 4; i++) {
      int temp = 0;
      for (int j = 0; j < 2; j++) {
        if (cst[i][j] == 0) {
          temp += (-x[j]);
        } else {
          temp += (x[j]);
        }
      }
      max1[i] = max(max1[i], temp);
      min1[i] = min(min1[i], temp);
    }
  }
  scanf("%d", &c);
  int ans = INT_MAX, index = 0;
  for (int i = 1; i <= c; i++) {
    int x[2];
    scanf("%d%d", &x[0], &x[1]);
    int tp = 0;
    for (int i = 0; i < 4; i++) {
      int temp = 0;
      for (int j = 0; j < 2; j++) {
        if (cst[i][j] == 0) {
          temp += (-x[j]);
        } else {
          temp += (x[j]);
        }
      }
      tp = max(tp, max(max1[i] - temp, temp - min1[i]));
    }
    if (tp < ans) {
      ans = tp;
      index = i;
    }
  }
  printf("%d\n%d\n", ans, index);
  return 0;
}
