#include <bits/stdc++.h>
using namespace std;
const int dx[] = {0, 0, -1, 1, 1, -1, -1, 1};
const int dy[] = {-1, 1, 0, 0, -1, 1, -1, 1};
const int MOD = 1000000007;
const int N = 1e5 + 50;
const long long OO = 100000000;
int n, m;
vector<long long> vec2;
long long bns(int l, int r, long long val) {
  if (r <= l) {
    if (vec2[l] == val)
      return l;
    else if (l != m - 1 && (abs(vec2[l] - val) <= abs(vec2[l + 1] - val))) {
      if (l - 1 >= 0) {
        if ((abs(vec2[l] - val) <= abs(vec2[l - 1] - val)))
          return l;
        else
          return l - 1;
      } else
        return l;
    } else {
      if (l != m - 1)
        return l + 1;
      else {
        if (l - 1 >= 0) {
          if ((abs(vec2[l - 1] - val) <= abs(vec2[l] - val)))
            return l - 1;
          else
            return l;
        } else
          return l;
      }
    }
  }
  int mid = (l + r) / 2;
  if (val > vec2[mid]) return bns(mid + 1, r, val);
  if (val < vec2[mid])
    return bns(l, mid - 1, val);
  else
    return mid;
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> m;
  vector<long long> vec1(n);
  for (int i = 0; i < n; ++i) {
    cin >> vec1[i];
  }
  int u;
  for (int i = 0; i < m; ++i) {
    cin >> u;
    vec2.push_back(u);
  }
  long long ans = -1 * OO;
  for (int i = 0; i < n; ++i) {
    long long y = bns(0, m - 1, vec1[i]);
    ans = max(ans, abs(vec1[i] - vec2[y]));
  }
  cout << ans;
  return 0;
}
