#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long n = 0, na = 0, nb = 0;
  cin >> n;
  long long chance = 0, score_a = 0, score_b = 0;
  vector<long long> a(n + 1, 0), b(n + 1, 0);
  for (auto i = 0; i < n; i += 1) cin >> a[i];
  for (auto i = 0; i < n; i += 1) cin >> b[i];
  sort((a).begin(), (a).end(), greater<long long>());
  sort((b).begin(), (b).end(), greater<long long>());
  while (chance < 2 * n) {
    if (chance & 1) {
      if (a[na] >= b[nb])
        na++;
      else {
        score_b += b[nb];
        nb++;
      }
    } else {
      if (b[nb] >= a[na])
        nb++;
      else {
        score_a += a[na];
        na++;
      }
    }
    chance++;
  }
  long long ans = score_a - score_b;
  cout << ans << "\n";
  return 0;
}
