#include <bits/stdc++.h>
using namespace std;
inline long long read() {
  long long s = 0;
  bool f = 0;
  char ch = ' ';
  while (!isdigit(ch)) {
    f |= (ch == '-');
    ch = getchar();
  }
  while (isdigit(ch)) {
    s = (s << 3) + (s << 1) + (ch ^ 48);
    ch = getchar();
  }
  return (f) ? (-s) : (s);
}
inline void write(long long x) {
  if (x < 0) {
    putchar('-');
    x = -x;
  }
  if (x < 10) {
    putchar(x + '0');
    return;
  }
  write(x / 10);
  putchar((x % 10) + '0');
}
const int N = 100005;
const long long inf = 1e11;
int rr, cc, n, m;
struct point {
  int x, y;
} a[N];
long long jyl[N], jzx;
int main() {
  int i;
  long long x, y, a, b, c, d;
  a = b = c = d = -inf;
  rr = read();
  cc = read();
  n = read();
  for (i = 1; i <= n; i++) {
    x = read();
    y = read();
    a = max(a, -x - y);
    b = max(b, -x + y);
    c = max(c, +x - y);
    d = max(d, +x + y);
  }
  jyl[0] = inf;
  m = read();
  for (i = 1; i <= m; i++) {
    x = read();
    y = read();
    jyl[i] = max(max(a + x + y, b + x - y), max(c - x + y, d - x - y));
    if (jyl[i] < jyl[jzx]) jzx = i;
  }
  write(jyl[jzx]), putchar('\n');
  write(jzx), putchar('\n');
  return 0;
}
