import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner reader = new Scanner(System.in);
		int N = reader.nextInt();
		int[] A = new int[N];
		int[] B = new int[N];
		for (int i = 0; i < N; i++) {
			A[i] = reader.nextInt();
		}
		for (int i = 0; i < N; i++) {
			B[i] = reader.nextInt();
		}
		int ans = 0;
		for (int i = 0; i < N; i++) {
			int tmp = 0;
			for (int j = 0; j <= i; j++) {
				tmp += A[j];
			}
			for (int j = i; j < N; j++) {
				tmp += B[j];
			}
			ans = Math.max(ans, tmp);
		}


		System.out.print(ans);
		reader.close();
	}
}


 import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {
		Scanner reader = new Scanner(System.in);
		int N = reader.nextInt();
		int[] A = new int[N];
		int[] B = new int[N];
		for (int i = 0; i < N; i++) {
			A[i] = reader.nextInt();
		}
		for (int i = 0; i < N; i++) {
			B[i] = reader.nextInt();
		}
		int ans = 0;
		for (int i = 0; i < N; i++) {
			int tmp = 0;
			for (int j = 0; j <= i; j++) {
				tmp += A[j];
			}
			for (int j = i; j < N; j++) {
				tmp += B[j];
			}
			ans = Math.max(ans, tmp);
		}


		System.out.print(ans);
		reader.close();
	}
} Main public static void main(String[] args) {
		Scanner reader = new Scanner(System.in);
		int N = reader.nextInt();
		int[] A = new int[N];
		int[] B = new int[N];
		for (int i = 0; i < N; i++) {
			A[i] = reader.nextInt();
		}
		for (int i = 0; i < N; i++) {
			B[i] = reader.nextInt();
		}
		int ans = 0;
		for (int i = 0; i < N; i++) {
			int tmp = 0;
			for (int j = 0; j <= i; j++) {
				tmp += A[j];
			}
			for (int j = i; j < N; j++) {
				tmp += B[j];
			}
			ans = Math.max(ans, tmp);
		}


		System.out.print(ans);
		reader.close();
	} main {
		Scanner reader = new Scanner(System.in);
		int N = reader.nextInt();
		int[] A = new int[N];
		int[] B = new int[N];
		for (int i = 0; i < N; i++) {
			A[i] = reader.nextInt();
		}
		for (int i = 0; i < N; i++) {
			B[i] = reader.nextInt();
		}
		int ans = 0;
		for (int i = 0; i < N; i++) {
			int tmp = 0;
			for (int j = 0; j <= i; j++) {
				tmp += A[j];
			}
			for (int j = i; j < N; j++) {
				tmp += B[j];
			}
			ans = Math.max(ans, tmp);
		}


		System.out.print(ans);
		reader.close();
	} Scanner reader = new Scanner(System.in); reader new Scanner(System.in) int N = reader.nextInt(); N reader.nextInt() reader.nextInt reader int[] A = new int[N]; A new int[N] N int[] B = new int[N]; B new int[N] N for (int i = 0; i < N; i++) {
			A[i] = reader.nextInt();
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			A[i] = reader.nextInt();
		} {
			A[i] = reader.nextInt();
		} A[i] = reader.nextInt() A[i] A i reader.nextInt() reader.nextInt reader for (int i = 0; i < N; i++) {
			B[i] = reader.nextInt();
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			B[i] = reader.nextInt();
		} {
			B[i] = reader.nextInt();
		} B[i] = reader.nextInt() B[i] B i reader.nextInt() reader.nextInt reader int ans = 0; ans 0 for (int i = 0; i < N; i++) {
			int tmp = 0;
			for (int j = 0; j <= i; j++) {
				tmp += A[j];
			}
			for (int j = i; j < N; j++) {
				tmp += B[j];
			}
			ans = Math.max(ans, tmp);
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			int tmp = 0;
			for (int j = 0; j <= i; j++) {
				tmp += A[j];
			}
			for (int j = i; j < N; j++) {
				tmp += B[j];
			}
			ans = Math.max(ans, tmp);
		} {
			int tmp = 0;
			for (int j = 0; j <= i; j++) {
				tmp += A[j];
			}
			for (int j = i; j < N; j++) {
				tmp += B[j];
			}
			ans = Math.max(ans, tmp);
		} int tmp = 0; tmp 0 for (int j = 0; j <= i; j++) {
				tmp += A[j];
			} int j = 0; int j = 0; j 0 j <= i j i j++ j++ j {
				tmp += A[j];
			} {
				tmp += A[j];
			} tmp += A[j] tmp A[j] A j for (int j = i; j < N; j++) {
				tmp += B[j];
			} int j = i; int j = i; j i j < N j N j++ j++ j {
				tmp += B[j];
			} {
				tmp += B[j];
			} tmp += B[j] tmp B[j] B j ans = Math.max(ans, tmp) ans Math.max(ans, tmp) Math.max Math ans tmp System.out.print(ans) System.out.print System.out System System.out ans reader.close() reader.close reader String[] args args public class Main {
	public static void main(String[] args) {
		Scanner reader = new Scanner(System.in);
		int N = reader.nextInt();
		int[] A = new int[N];
		int[] B = new int[N];
		for (int i = 0; i < N; i++) {
			A[i] = reader.nextInt();
		}
		for (int i = 0; i < N; i++) {
			B[i] = reader.nextInt();
		}
		int ans = 0;
		for (int i = 0; i < N; i++) {
			int tmp = 0;
			for (int j = 0; j <= i; j++) {
				tmp += A[j];
			}
			for (int j = i; j < N; j++) {
				tmp += B[j];
			}
			ans = Math.max(ans, tmp);
		}


		System.out.print(ans);
		reader.close();
	}
} public class Main {
	public static void main(String[] args) {
		Scanner reader = new Scanner(System.in);
		int N = reader.nextInt();
		int[] A = new int[N];
		int[] B = new int[N];
		for (int i = 0; i < N; i++) {
			A[i] = reader.nextInt();
		}
		for (int i = 0; i < N; i++) {
			B[i] = reader.nextInt();
		}
		int ans = 0;
		for (int i = 0; i < N; i++) {
			int tmp = 0;
			for (int j = 0; j <= i; j++) {
				tmp += A[j];
			}
			for (int j = i; j < N; j++) {
				tmp += B[j];
			}
			ans = Math.max(ans, tmp);
		}


		System.out.print(ans);
		reader.close();
	}
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {
		Scanner reader = new Scanner(System.in);
		int N = reader.nextInt();
		int[] A = new int[N];
		int[] B = new int[N];
		for (int i = 0; i < N; i++) {
			A[i] = reader.nextInt();
		}
		for (int i = 0; i < N; i++) {
			B[i] = reader.nextInt();
		}
		int ans = 0;
		for (int i = 0; i < N; i++) {
			int tmp = 0;
			for (int j = 0; j <= i; j++) {
				tmp += A[j];
			}
			for (int j = i; j < N; j++) {
				tmp += B[j];
			}
			ans = Math.max(ans, tmp);
		}


		System.out.print(ans);
		reader.close();
	}
}



