#include <bits/stdc++.h>
using namespace std;
int n, m;
double xa, xb, la[100010];
double yl[100010], yr[100010], l[100010];
inline int cmpf(double a, double b) {
  if (fabs(a - b) < 1e-7) return 0;
  return a < b ? -1 : 1;
}
inline double dist(double x1, double y1, double x2, double y2) {
  return sqrt((x2 - x1) * (x2 - x1) + (y2 - y1) * (y2 - y1));
}
int main() {
  scanf("%d %d %lf %lf", &n, &m, &xa, &xb);
  for (int i = 0; i < n; i++) scanf("%lf", yl + i);
  for (int i = 0; i < m; i++) scanf("%lf", yr + i);
  for (int i = 0; i < m; i++) scanf("%lf", l + i);
  for (int i = 0; i < n; i++) la[i] = dist(0, 0, xa, yl[i]);
  double menor = 1e50;
  int r1, r2;
  for (int i = 0; i < m; i++) {
    int ini = 0, fim = n - 1;
    double d1 = l[i];
    while (fim - ini > 2) {
      int p = (fim - ini + 1) / 3;
      int j1 = ini + p - 1;
      int j2 = fim - p + 1;
      double f1 = d1 + dist(xb, yr[i], xa, yl[j1]) + la[j1];
      double f2 = d1 + dist(xb, yr[i], xa, yl[j2]) + la[j2];
      if (cmpf(f1, menor) < 0) {
        menor = f1;
        r1 = j1;
        r2 = i;
      }
      if (cmpf(f2, menor) < 0) {
        menor = f2;
        r1 = j2;
        r2 = i;
      }
      if (f1 < f2)
        fim = j2 - 1;
      else
        ini = j1 + 1;
    }
    for (int j = ini; j <= fim; j++) {
      double f = d1 + dist(xb, yr[i], xa, yl[j]) + dist(0, 0, xa, yl[j]);
      if (cmpf(f, menor) < 0) {
        menor = f;
        r1 = j;
        r2 = i;
      }
    }
  }
  printf("%d %d\n", r1 + 1, r2 + 1);
  return 0;
}
