#include <bits/stdc++.h>
using namespace std;
vector<int> vecn;
vector<int> vecm;
int main() {
  int n, m, x, ans = 0;
  cin >> n >> m;
  for (int i = 0; i < n; i++) {
    cin >> x;
    vecn.push_back(x);
  }
  for (int i = 0; i < m; i++) {
    cin >> x;
    vecm.push_back(x);
  }
  for (int i = 0; i < n; i++) {
    int l = lower_bound(vecm.begin(), vecm.end(), vecn[i]) - vecm.begin();
    if (l == 0) ans = max(ans, vecm[l] - vecn[i]);
    if (l == m)
      ans = max(ans, vecn[i] - vecm[l - 1]);
    else
      ans = max(ans, min(vecm[l] - vecn[i], vecn[i] - vecm[l - 1]));
  }
  cout << ans;
}
