import java.io.*;
import java.util.*;

public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader f = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
    
    int a = Integer.parseInt(f.readLine());
    StringTokenizer vals = new StringTokenizer(f.readLine());
    StringTokenizer costs = new StringTokenizer(f.readLine());
    
    int val;
    int cost;
    int profit = 0;
    
    for (int i = 0; i < a; i++) {
      val = Integer.parseInt(vals.nextToken());
      cost = Integer.parseInt(costs.nextToken());
      if (val > cost) {
        profit += val - cost;
      }
    }
    
    out.write(String.valueOf(profit));
    out.close();
  }
} import java.io.*; io.* java import java.util.*; util.* java public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader f = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
    
    int a = Integer.parseInt(f.readLine());
    StringTokenizer vals = new StringTokenizer(f.readLine());
    StringTokenizer costs = new StringTokenizer(f.readLine());
    
    int val;
    int cost;
    int profit = 0;
    
    for (int i = 0; i < a; i++) {
      val = Integer.parseInt(vals.nextToken());
      cost = Integer.parseInt(costs.nextToken());
      if (val > cost) {
        profit += val - cost;
      }
    }
    
    out.write(String.valueOf(profit));
    out.close();
  }
} Main public static void main(String[] args) throws IOException {
    BufferedReader f = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
    
    int a = Integer.parseInt(f.readLine());
    StringTokenizer vals = new StringTokenizer(f.readLine());
    StringTokenizer costs = new StringTokenizer(f.readLine());
    
    int val;
    int cost;
    int profit = 0;
    
    for (int i = 0; i < a; i++) {
      val = Integer.parseInt(vals.nextToken());
      cost = Integer.parseInt(costs.nextToken());
      if (val > cost) {
        profit += val - cost;
      }
    }
    
    out.write(String.valueOf(profit));
    out.close();
  } main {
    BufferedReader f = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
    
    int a = Integer.parseInt(f.readLine());
    StringTokenizer vals = new StringTokenizer(f.readLine());
    StringTokenizer costs = new StringTokenizer(f.readLine());
    
    int val;
    int cost;
    int profit = 0;
    
    for (int i = 0; i < a; i++) {
      val = Integer.parseInt(vals.nextToken());
      cost = Integer.parseInt(costs.nextToken());
      if (val > cost) {
        profit += val - cost;
      }
    }
    
    out.write(String.valueOf(profit));
    out.close();
  } BufferedReader f = new BufferedReader(new InputStreamReader(System.in)); f new BufferedReader(new InputStreamReader(System.in)) PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out))); out new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out))) int a = Integer.parseInt(f.readLine()); a Integer.parseInt(f.readLine()) Integer.parseInt Integer f.readLine() f.readLine f StringTokenizer vals = new StringTokenizer(f.readLine()); vals new StringTokenizer(f.readLine()) StringTokenizer costs = new StringTokenizer(f.readLine()); costs new StringTokenizer(f.readLine()) int val; val int cost; cost int profit = 0; profit 0 for (int i = 0; i < a; i++) {
      val = Integer.parseInt(vals.nextToken());
      cost = Integer.parseInt(costs.nextToken());
      if (val > cost) {
        profit += val - cost;
      }
    } int i = 0; int i = 0; i 0 i < a i a i++ i++ i {
      val = Integer.parseInt(vals.nextToken());
      cost = Integer.parseInt(costs.nextToken());
      if (val > cost) {
        profit += val - cost;
      }
    } {
      val = Integer.parseInt(vals.nextToken());
      cost = Integer.parseInt(costs.nextToken());
      if (val > cost) {
        profit += val - cost;
      }
    } val = Integer.parseInt(vals.nextToken()) val Integer.parseInt(vals.nextToken()) Integer.parseInt Integer vals.nextToken() vals.nextToken vals cost = Integer.parseInt(costs.nextToken()) cost Integer.parseInt(costs.nextToken()) Integer.parseInt Integer costs.nextToken() costs.nextToken costs if (val > cost) {
        profit += val - cost;
      } val > cost val cost {
        profit += val - cost;
      } profit += val - cost profit val - cost val cost out.write(String.valueOf(profit)) out.write out String.valueOf(profit) String.valueOf String profit out.close() out.close out String[] args args public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader f = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
    
    int a = Integer.parseInt(f.readLine());
    StringTokenizer vals = new StringTokenizer(f.readLine());
    StringTokenizer costs = new StringTokenizer(f.readLine());
    
    int val;
    int cost;
    int profit = 0;
    
    for (int i = 0; i < a; i++) {
      val = Integer.parseInt(vals.nextToken());
      cost = Integer.parseInt(costs.nextToken());
      if (val > cost) {
        profit += val - cost;
      }
    }
    
    out.write(String.valueOf(profit));
    out.close();
  }
} public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader f = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
    
    int a = Integer.parseInt(f.readLine());
    StringTokenizer vals = new StringTokenizer(f.readLine());
    StringTokenizer costs = new StringTokenizer(f.readLine());
    
    int val;
    int cost;
    int profit = 0;
    
    for (int i = 0; i < a; i++) {
      val = Integer.parseInt(vals.nextToken());
      cost = Integer.parseInt(costs.nextToken());
      if (val > cost) {
        profit += val - cost;
      }
    }
    
    out.write(String.valueOf(profit));
    out.close();
  }
} Main
import java.io.*;
import java.util.*;

public class Main {
  public static void main(String[] args) throws IOException {
    BufferedReader f = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter out = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));
    
    int a = Integer.parseInt(f.readLine());
    StringTokenizer vals = new StringTokenizer(f.readLine());
    StringTokenizer costs = new StringTokenizer(f.readLine());
    
    int val;
    int cost;
    int profit = 0;
    
    for (int i = 0; i < a; i++) {
      val = Integer.parseInt(vals.nextToken());
      cost = Integer.parseInt(costs.nextToken());
      if (val > cost) {
        profit += val - cost;
      }
    }
    
    out.write(String.valueOf(profit));
    out.close();
  }
}
