#include <bits/stdc++.h>
using namespace std;
long long int power(long long int x, long long int y) {
  if (y == 0)
    return 1;
  else if (y % 2 == 0)
    return power(x * x, y / 2);
  else
    return x * power(x * x, y / 2);
}
long long int gcd(long long int a, long long int b) {
  if (b == 0)
    return a;
  else
    return gcd(b, a % b);
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long int n;
  cin >> n;
  long long int A[n], B[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);
  sort(B, B + n);
  int i = n - 1, j = n - 1, c = 0;
  long long int a = 0, b = 0;
  while (i >= 0 and j >= 0) {
    if (c == 0) {
      if (A[i] > B[j]) {
        a += A[i];
        i--;
      } else {
        j--;
      }
      c = 1;
    } else {
      if (B[j] > A[i]) {
        b += B[j];
        j--;
      } else {
        i--;
      }
      c = 0;
    }
  }
  while (j >= 0) {
    if (c == 0) {
      j--;
      c = 1;
    } else {
      b += B[j];
      j--;
      c = 0;
    }
  }
  while (i >= 0) {
    if (c == 1) {
      i--;
      c = 0;
    } else {
      a += A[i];
      i--;
      c = 1;
    }
  }
  cout << a - b << "\n";
  return 0;
}
