n = int(input()) if n <= 2: print(0) exit() xy = [] for _ in range(n): x, y = map(int, input().split()) xy.append((x + y, x - y)) xy.sort() inf = 1 << 40 mi_y = inf ma_y = -inf X = [0] * (n - 1) for i in range(n - 1): mi_y = min(mi_y, xy[i][1]) ma_y = max(ma_y, xy[i][1]) dy = (ma_y - mi_y) dx = xy[i][0] - xy[0][0] X[i] = max(dx, dy) mi_y = inf ma_y = -inf for i in range(n - 1, 0, -1): mi_y = min(mi_y, xy[i][1]) ma_y = max(ma_y, xy[i][1]) dy = (ma_y - mi_y) dx = xy[-1][0] - xy[i][0] X[i - 1] = max(X[i - 1], dx, dy) ans = min(X) xy.sort(key=lambda x:x[1]) inf = 1 << 40 mi_y = inf ma_y = -inf X = [0] * (n - 1) for i in range(n - 1): mi_y = min(mi_y, xy[i][0]) ma_y = max(ma_y, xy[i][0]) dy = (ma_y - mi_y) dx = xy[i][1] - xy[0][1] X[i] = max(dx, dy) mi_y = inf ma_y = -inf for i in range(n - 1, 0, -1): mi_y = min(mi_y, xy[i][0]) ma_y = max(ma_y, xy[i][0]) dy = (ma_y - mi_y) dx = xy[-1][1] - xy[i][1] X[i - 1] = max(X[i - 1], dx, dy) ans = min(ans, *X) print(ans // 2)