#include <bits/stdc++.h>
using namespace std;
struct P {
  P() { x = y = 1000000002; }
  int x, y;
};
struct M {
  M() { d = 2000000002; }
  int d;
  P sim;
};
int main() {
  int n, m, c, mx, mn, mnin;
  P pos;
  M far[5];
  scanf("%d %d", &n, &m);
  scanf("%d", &c);
  for (int i = 1; i <= c; i++) {
    scanf("%d %d", &pos.x, &pos.y);
    if (pos.x + pos.y <= far[0].d) {
      far[0].d = pos.x + pos.y;
      far[0].sim = pos;
    }
    if (abs(n - pos.x) + pos.y <= far[1].d) {
      far[1].d = abs(n - pos.x) + pos.y;
      far[1].sim = pos;
    }
    if (pos.x + abs(m - pos.y) <= far[2].d) {
      far[2].d = pos.x + abs(m - pos.y);
      far[2].sim = pos;
    }
    if (abs(n - pos.x) + abs(m - pos.y) <= far[3].d) {
      far[3].d = abs(n - pos.x) + abs(m - pos.y);
      far[3].sim = pos;
    }
  }
  scanf("%d", &c);
  mn = 2000000002;
  mnin = 0;
  for (int i = 1; i <= c; i++) {
    scanf("%d %d", &pos.x, &pos.y);
    mx = 0;
    for (int j = 0; j <= 3; j++)
      mx = max(mx, abs(far[j].sim.x - pos.x) + abs(far[j].sim.y - pos.y));
    if (mn > mx) {
      mn = mx;
      mnin = i;
    }
  }
  printf("%d\n%d", mn, mnin);
  return 0;
}
