import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		
		int N = 0, ans = 0;

		Scanner scanner = new Scanner(System.in);
		
		N = scanner.nextInt();
		int[] benefit = new int[N];
		
		for (int i = 0; i < N; i++) {
			benefit[i] = scanner.nextInt();
		}
		
		for (int i = 0; i < N; i++) {
			benefit[i] = benefit[i] - scanner.nextInt();
			ans = Math.max(ans, ans + benefit[i]);
		}
		
		scanner.close();
		
		System.out.println(ans);
		
		
	}

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

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		
		int N = 0, ans = 0;

		Scanner scanner = new Scanner(System.in);
		
		N = scanner.nextInt();
		int[] benefit = new int[N];
		
		for (int i = 0; i < N; i++) {
			benefit[i] = scanner.nextInt();
		}
		
		for (int i = 0; i < N; i++) {
			benefit[i] = benefit[i] - scanner.nextInt();
			ans = Math.max(ans, ans + benefit[i]);
		}
		
		scanner.close();
		
		System.out.println(ans);
		
		
	}

} Main public static void main(String[] args) {
		// TODO Auto-generated method stub
		
		int N = 0, ans = 0;

		Scanner scanner = new Scanner(System.in);
		
		N = scanner.nextInt();
		int[] benefit = new int[N];
		
		for (int i = 0; i < N; i++) {
			benefit[i] = scanner.nextInt();
		}
		
		for (int i = 0; i < N; i++) {
			benefit[i] = benefit[i] - scanner.nextInt();
			ans = Math.max(ans, ans + benefit[i]);
		}
		
		scanner.close();
		
		System.out.println(ans);
		
		
	} main {
		// TODO Auto-generated method stub
		
		int N = 0, ans = 0;

		Scanner scanner = new Scanner(System.in);
		
		N = scanner.nextInt();
		int[] benefit = new int[N];
		
		for (int i = 0; i < N; i++) {
			benefit[i] = scanner.nextInt();
		}
		
		for (int i = 0; i < N; i++) {
			benefit[i] = benefit[i] - scanner.nextInt();
			ans = Math.max(ans, ans + benefit[i]);
		}
		
		scanner.close();
		
		System.out.println(ans);
		
		
	} int N = 0 N 0 ans = 0; ans 0 Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) N = scanner.nextInt() N scanner.nextInt() scanner.nextInt scanner int[] benefit = new int[N]; benefit new int[N] N for (int i = 0; i < N; i++) {
			benefit[i] = scanner.nextInt();
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			benefit[i] = scanner.nextInt();
		} {
			benefit[i] = scanner.nextInt();
		} benefit[i] = scanner.nextInt() benefit[i] benefit i scanner.nextInt() scanner.nextInt scanner for (int i = 0; i < N; i++) {
			benefit[i] = benefit[i] - scanner.nextInt();
			ans = Math.max(ans, ans + benefit[i]);
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			benefit[i] = benefit[i] - scanner.nextInt();
			ans = Math.max(ans, ans + benefit[i]);
		} {
			benefit[i] = benefit[i] - scanner.nextInt();
			ans = Math.max(ans, ans + benefit[i]);
		} benefit[i] = benefit[i] - scanner.nextInt() benefit[i] benefit i benefit[i] - scanner.nextInt() benefit[i] benefit i scanner.nextInt() scanner.nextInt scanner ans = Math.max(ans, ans + benefit[i]) ans Math.max(ans, ans + benefit[i]) Math.max Math ans ans + benefit[i] ans benefit[i] benefit i scanner.close() scanner.close scanner System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		
		int N = 0, ans = 0;

		Scanner scanner = new Scanner(System.in);
		
		N = scanner.nextInt();
		int[] benefit = new int[N];
		
		for (int i = 0; i < N; i++) {
			benefit[i] = scanner.nextInt();
		}
		
		for (int i = 0; i < N; i++) {
			benefit[i] = benefit[i] - scanner.nextInt();
			ans = Math.max(ans, ans + benefit[i]);
		}
		
		scanner.close();
		
		System.out.println(ans);
		
		
	}

} public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		
		int N = 0, ans = 0;

		Scanner scanner = new Scanner(System.in);
		
		N = scanner.nextInt();
		int[] benefit = new int[N];
		
		for (int i = 0; i < N; i++) {
			benefit[i] = scanner.nextInt();
		}
		
		for (int i = 0; i < N; i++) {
			benefit[i] = benefit[i] - scanner.nextInt();
			ans = Math.max(ans, ans + benefit[i]);
		}
		
		scanner.close();
		
		System.out.println(ans);
		
		
	}

} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		
		int N = 0, ans = 0;

		Scanner scanner = new Scanner(System.in);
		
		N = scanner.nextInt();
		int[] benefit = new int[N];
		
		for (int i = 0; i < N; i++) {
			benefit[i] = scanner.nextInt();
		}
		
		for (int i = 0; i < N; i++) {
			benefit[i] = benefit[i] - scanner.nextInt();
			ans = Math.max(ans, ans + benefit[i]);
		}
		
		scanner.close();
		
		System.out.println(ans);
		
		
	}

}
