import java.util.*;
public class Main {

	public static void main(String[] args) {
		Scanner seer = new Scanner(System.in);
		int n = seer.nextInt();
		int[] arr = new int[n];
		for(int i = 0; i < n; i++){
			arr[i] = seer.nextInt();
		}
		int tot = 0;
		for(int i = 0; i < n; i++){
			int c = seer.nextInt();
			if(arr[i] > c) tot += arr[i]-c;
		}
		System.out.println(tot);
	}

} import java.util.*; util.* java public class Main {

	public static void main(String[] args) {
		Scanner seer = new Scanner(System.in);
		int n = seer.nextInt();
		int[] arr = new int[n];
		for(int i = 0; i < n; i++){
			arr[i] = seer.nextInt();
		}
		int tot = 0;
		for(int i = 0; i < n; i++){
			int c = seer.nextInt();
			if(arr[i] > c) tot += arr[i]-c;
		}
		System.out.println(tot);
	}

} Main public static void main(String[] args) {
		Scanner seer = new Scanner(System.in);
		int n = seer.nextInt();
		int[] arr = new int[n];
		for(int i = 0; i < n; i++){
			arr[i] = seer.nextInt();
		}
		int tot = 0;
		for(int i = 0; i < n; i++){
			int c = seer.nextInt();
			if(arr[i] > c) tot += arr[i]-c;
		}
		System.out.println(tot);
	} main {
		Scanner seer = new Scanner(System.in);
		int n = seer.nextInt();
		int[] arr = new int[n];
		for(int i = 0; i < n; i++){
			arr[i] = seer.nextInt();
		}
		int tot = 0;
		for(int i = 0; i < n; i++){
			int c = seer.nextInt();
			if(arr[i] > c) tot += arr[i]-c;
		}
		System.out.println(tot);
	} Scanner seer = new Scanner(System.in); seer new Scanner(System.in) int n = seer.nextInt(); n seer.nextInt() seer.nextInt seer int[] arr = new int[n]; arr new int[n] n for(int i = 0; i < n; i++){
			arr[i] = seer.nextInt();
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			arr[i] = seer.nextInt();
		} {
			arr[i] = seer.nextInt();
		} arr[i] = seer.nextInt() arr[i] arr i seer.nextInt() seer.nextInt seer int tot = 0; tot 0 for(int i = 0; i < n; i++){
			int c = seer.nextInt();
			if(arr[i] > c) tot += arr[i]-c;
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			int c = seer.nextInt();
			if(arr[i] > c) tot += arr[i]-c;
		} {
			int c = seer.nextInt();
			if(arr[i] > c) tot += arr[i]-c;
		} int c = seer.nextInt(); c seer.nextInt() seer.nextInt seer if(arr[i] > c) tot += arr[i]-c; arr[i] > c arr[i] arr i c tot += arr[i]-c tot arr[i]-c arr[i] arr i c System.out.println(tot) System.out.println System.out System System.out tot String[] args args public class Main {

	public static void main(String[] args) {
		Scanner seer = new Scanner(System.in);
		int n = seer.nextInt();
		int[] arr = new int[n];
		for(int i = 0; i < n; i++){
			arr[i] = seer.nextInt();
		}
		int tot = 0;
		for(int i = 0; i < n; i++){
			int c = seer.nextInt();
			if(arr[i] > c) tot += arr[i]-c;
		}
		System.out.println(tot);
	}

} public class Main {

	public static void main(String[] args) {
		Scanner seer = new Scanner(System.in);
		int n = seer.nextInt();
		int[] arr = new int[n];
		for(int i = 0; i < n; i++){
			arr[i] = seer.nextInt();
		}
		int tot = 0;
		for(int i = 0; i < n; i++){
			int c = seer.nextInt();
			if(arr[i] > c) tot += arr[i]-c;
		}
		System.out.println(tot);
	}

} Main
import java.util.*;
public class Main {

	public static void main(String[] args) {
		Scanner seer = new Scanner(System.in);
		int n = seer.nextInt();
		int[] arr = new int[n];
		for(int i = 0; i < n; i++){
			arr[i] = seer.nextInt();
		}
		int tot = 0;
		for(int i = 0; i < n; i++){
			int c = seer.nextInt();
			if(arr[i] > c) tot += arr[i]-c;
		}
		System.out.println(tot);
	}

}
