#include <bits/stdc++.h>
using namespace std;
template <class T1, class T2>
ostream& operator<<(ostream& out, pair<T1, T2> p) {
  out << p.first << ' ' << p.second;
  return out;
}
template <class T1, class T2>
istream& operator>>(istream& in, pair<T1, T2>& p) {
  in >> p.first >> p.second;
  return in;
}
template <class T>
istream& operator>>(istream& in, vector<T>& v) {
  for (auto& x : v) in >> x;
  return in;
}
template <class T>
ostream& operator<<(ostream& out, vector<vector<T>>& v) {
  for (auto& x : v) out << x << '\n';
  return out;
}
template <class T>
ostream& operator<<(ostream& out, vector<T>& v) {
  for (auto x : v) out << x << ' ';
  return out;
}
void solve() {
  long long n, a = 0, b = 0;
  cin >> n;
  vector<long long> va(n), vb(n);
  cin >> va >> vb;
  priority_queue<pair<long long, long long>> pq;
  for (long long i = 0; i < n; i++) {
    pq.push({va[i], 1});
    pq.push({vb[i], 0});
  }
  long long chance = 1;
  while (!pq.empty()) {
    pair<long long, long long> p = pq.top();
    pq.pop();
    if (chance == 1) {
      if (p.second == 1) a += p.first;
    }
    if (chance == 0 && p.second == 0) b += p.first;
    chance = !chance;
  }
  cout << a - b;
}
signed main() {
  ios::sync_with_stdio(0), cin.tie(0), cout.tie(0), cerr.tie(0);
  ;
  long long t;
  t = 1;
  while (t--) {
    solve();
  }
  return 0;
}
