import java.util.*;

class Main {
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    Integer a[] = new Integer[n];
    Integer b[] = new Integer[n];
    for (int i=0; i<n; i++){
      a[i] = sc.nextInt();
    }
    for (int i=0; i<n; i++){
      b[i] = sc.nextInt();
    }
    int sum =0;   
    for (int i=0; i<n; i++){
      int v = a[i] -b[i];
      if (v>0){
        sum += v;
      }
    }
    System.out.println(sum);
  }
} import java.util.*; util.* java class Main {
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    Integer a[] = new Integer[n];
    Integer b[] = new Integer[n];
    for (int i=0; i<n; i++){
      a[i] = sc.nextInt();
    }
    for (int i=0; i<n; i++){
      b[i] = sc.nextInt();
    }
    int sum =0;   
    for (int i=0; i<n; i++){
      int v = a[i] -b[i];
      if (v>0){
        sum += v;
      }
    }
    System.out.println(sum);
  }
} Main public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    Integer a[] = new Integer[n];
    Integer b[] = new Integer[n];
    for (int i=0; i<n; i++){
      a[i] = sc.nextInt();
    }
    for (int i=0; i<n; i++){
      b[i] = sc.nextInt();
    }
    int sum =0;   
    for (int i=0; i<n; i++){
      int v = a[i] -b[i];
      if (v>0){
        sum += v;
      }
    }
    System.out.println(sum);
  } main {
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    Integer a[] = new Integer[n];
    Integer b[] = new Integer[n];
    for (int i=0; i<n; i++){
      a[i] = sc.nextInt();
    }
    for (int i=0; i<n; i++){
      b[i] = sc.nextInt();
    }
    int sum =0;   
    for (int i=0; i<n; i++){
      int v = a[i] -b[i];
      if (v>0){
        sum += v;
      }
    }
    System.out.println(sum);
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc Integer a[] = new Integer[n]; a new Integer[n] n Integer b[] = new Integer[n]; b new Integer[n] n for (int i=0; i<n; i++){
      a[i] = sc.nextInt();
    } int i=0; int i=0; i 0 i<n i n i++ i++ i {
      a[i] = sc.nextInt();
    } {
      a[i] = sc.nextInt();
    } a[i] = sc.nextInt() a[i] a i sc.nextInt() sc.nextInt sc for (int i=0; i<n; i++){
      b[i] = sc.nextInt();
    } int i=0; int i=0; i 0 i<n i n i++ i++ i {
      b[i] = sc.nextInt();
    } {
      b[i] = sc.nextInt();
    } b[i] = sc.nextInt() b[i] b i sc.nextInt() sc.nextInt sc int sum =0; sum 0 for (int i=0; i<n; i++){
      int v = a[i] -b[i];
      if (v>0){
        sum += v;
      }
    } int i=0; int i=0; i 0 i<n i n i++ i++ i {
      int v = a[i] -b[i];
      if (v>0){
        sum += v;
      }
    } {
      int v = a[i] -b[i];
      if (v>0){
        sum += v;
      }
    } int v = a[i] -b[i]; v a[i] -b[i] a[i] a i b[i] b i if (v>0){
        sum += v;
      } v>0 v 0 {
        sum += v;
      } sum += v sum v System.out.println(sum) System.out.println System.out System System.out sum String[] args args
import java.util.*;

class Main {
  public static void main(String[] args){
    Scanner sc = new Scanner(System.in);
    int n = sc.nextInt();
    Integer a[] = new Integer[n];
    Integer b[] = new Integer[n];
    for (int i=0; i<n; i++){
      a[i] = sc.nextInt();
    }
    for (int i=0; i<n; i++){
      b[i] = sc.nextInt();
    }
    int sum =0;   
    for (int i=0; i<n; i++){
      int v = a[i] -b[i];
      if (v>0){
        sum += v;
      }
    }
    System.out.println(sum);
  }
}