#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, a[100005], b[100005];
  cin >> n;
  for (int i = 0; i < n; i++) cin >> a[i];
  for (int i = 0; i < n; i++) cin >> b[i];
  sort(a, a + n, greater<int>());
  sort(b, b + n, greater<int>());
  long long A = 0, B = 0;
  int cA = 0, cB = 0, i = 0;
  while (cA < n || cB < n) {
    if (i % 2 == 0) {
      if (cA < n && (cB >= n || a[cA] >= b[cB])) {
        A += a[cA];
        cA++;
      } else {
        cB++;
      }
    } else {
      if (cB < n && (cA >= n || a[cA] <= b[cB])) {
        B += b[cB];
        cB++;
      } else {
        cA++;
      }
    }
    i++;
  }
  cout << (A - B) << endl;
}
