#include <bits/stdc++.h>
using namespace std;
int Closest(int x, int y, int target) {
  if (abs(x - target) < abs(y - target)) {
    return x;
  }
  return y;
}
int main() {
  int n, m;
  cin >> n >> m;
  int A[n], B[m];
  for (int i = 0; i < n; ++i) {
    cin >> A[i];
  }
  for (int i = 0; i < m; ++i) {
    cin >> B[i];
  }
  sort(A, A + n);
  sort(B, B + m);
  int closest[n];
  int j = 0;
  for (int i = 0; i < n; i++) {
    while (j < (m - 1) && B[j + 1] < A[i]) {
      j++;
    }
    if (j == m - 1) {
      closest[i] = B[j];
      continue;
    }
    closest[i] = Closest(B[j], B[j + 1], A[i]);
  }
  int c_ans = 0;
  for (int i = 0; i < n; i++) {
    c_ans = max(c_ans, abs(A[i] - closest[i]));
  }
  cout << c_ans << endl;
}
