#include <bits/stdc++.h>
using namespace std;
template <typename Arg1>
void __f(const char* name, Arg1&& arg1) {
  cerr << name << " : " << arg1 << '\n';
  ;
}
template <typename Arg1, typename... Args>
void __f(const char* names, Arg1&& arg1, Args&&... args) {
  const char* comma = strchr(names + 1, ',');
  cerr.write(names, comma - names) << " : " << arg1 << " | ";
  __f(comma + 1, args...);
}
long long POSITIVE_INFINITY = 9223372036854775807;
long long NEGATIVE_INFINITY = -9223372036854775807;
long double PI = acos(-1.0);
long long MOD = 1000000007;
long long INF = 1e18;
long long N = 1000001;
int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  ;
  long long n;
  cin >> n;
  vector<long long> a(n + 5, 0), b(n + 5, 0);
  for (long long i = 0; i < n; ++i) cin >> a[i];
  for (long long i = 0; i < n; ++i) cin >> b[i];
  sort(a.begin(), a.end(), greater<long long>());
  sort(b.begin(), b.end(), greater<long long>());
  long long i = 0, j = 0;
  long long suma = 0, sumb = 0, moves = 0;
  char turn = 'a';
  while (moves < 2 * n) {
    moves++;
    if (turn == 'a') {
      if (a[i] >= b[j])
        suma += a[i++];
      else
        j++;
      turn = 'b';
    } else {
      if (a[i] <= b[j])
        sumb += b[j++];
      else
        i++;
      turn = 'a';
    }
  }
  cout << suma - sumb << '\n';
  ;
  return 0;
}
