#include <bits/stdc++.h>
#define ALL(a) (a).begin(),(a).end()
#define RALL(a) (a).rbegin(),(a).rend()
#define pb push_back
#define FOR(i,a,b) for(int i=(a);i<(b);++i)
#define REP(i,n)  FOR(i,0,n)
#define ll long long
using namespace std;
int main(){
  int n;
  int v[50], c[50];
  cin >> n;
  REP(i, n)cin >> v[i];
  REP(i, n)cin >> c[i];
  int ans = 0;
  REP(i, n) if (v[i] > c[i]) ans += v[i] - c[i];
  cout << ans << endl;
  return 0;
}
