#include<queue>
#include<>
#include<iostream>
#include<algorithm>
using namespace std;
int n,ans;
int T[2010],Q[2010];
inline int read() {
int x=0,f=1;
char ch=getchar();
while (ch<'0'||ch>'9') {
if (ch=='-') f=-1;
ch=getchar();
}
while (ch>='0'&&ch<='9') {
x=x*10+ch-48;
ch=getchar();
}
return x*f;
}
bool cmp(int x,int y) {
return x < y;
}
deque <int> q1;
deque <int> q2;
int main() {
n = read();
for(int i = 1 ; i <= n ; i ++)
T[i] = read();
for(int i = 1 ; i <= n ; i ++)
Q[i] = read();
sort(T + 1,T + 1 + n,cmp);
sort(Q + 1,Q + 1 + n,cmp);
for(int i = 1 ; i <= n ; i ++) {
q1.push_back(T[i]);
q2.push_back(Q[i]);
}
while(!q1.empty()) {
int x1 = q1.front(),x2 = q2.front();
int y1 = q1.back(),y2 = q2.back();
if(x1 > x2) {
q1.pop_front();
q2.pop_front();
ans += 200;
} else if(x1 < x2) {
q1.pop_front();
q2.pop_back();
ans -= 200;
} else {
if(y1 > y2) {
q1.pop_back();
q2.pop_back();
ans += 200;
} else if(y1 < y2) {
q1.pop_front();
q2.pop_back();
ans -= 200;
} else {
q1.pop_front();
q2.pop_back();
ans -= 200;
}
}
}
cout << ans;
return 0;
}