#include <bits/stdc++.h>
using namespace std;
const int maxn = 100010;
int n, m, t;
int a[maxn], b[maxn], T[maxn], L[maxn], d[maxn];
bool v[maxn];
int main() {
  scanf("%d%d%d%d", &n, &m, &t, &t);
  for (int i = 0; i < n; ++i) scanf("%d", &a[i]);
  for (int i = 0; i < m; ++i) scanf("%d", &b[i]);
  int ans = 0;
  for (int i = 0, t = 0; i < n; ++i) {
    while (t + 1 < m && abs(a[i] - b[t]) > abs(a[i] - b[t + 1])) ++t;
    int D = abs(a[i] - b[t]);
    if (!v[t] || (v[t] && D == L[t])) {
      ++ans;
      v[t] = true;
      L[t] = D;
    } else if (t + 1 < m && abs(a[i] - b[t + 1]) == D &&
               (!v[t + 1] || (v[t + 1] && L[t + 1] == D))) {
      ++ans;
      v[t + 1] = true;
      L[t + 1] = D;
    } else if (D < L[t]) {
      L[t] = D;
    }
  }
  printf("%d\n", n - ans);
  return 0;
}
