import java.util.*;

public class Main {

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] uarr = new int[n];
		int[] darr = new int[n];
		for (int i = 0; i < n; i++) {
			uarr[i] = sc.nextInt();
		}
		for (int i = 0; i < n; i++) {
			darr[i] = sc.nextInt();
		}
		int max = 0;
		for (int i = 0; i < n; i++) {
			int count = 0;
			for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			}
			if (count > max) {
				max = count;
			}
		}
		System.out.println(max);
	}
} import java.util.*; util.* java public class Main {

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] uarr = new int[n];
		int[] darr = new int[n];
		for (int i = 0; i < n; i++) {
			uarr[i] = sc.nextInt();
		}
		for (int i = 0; i < n; i++) {
			darr[i] = sc.nextInt();
		}
		int max = 0;
		for (int i = 0; i < n; i++) {
			int count = 0;
			for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			}
			if (count > max) {
				max = count;
			}
		}
		System.out.println(max);
	}
} Main public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] uarr = new int[n];
		int[] darr = new int[n];
		for (int i = 0; i < n; i++) {
			uarr[i] = sc.nextInt();
		}
		for (int i = 0; i < n; i++) {
			darr[i] = sc.nextInt();
		}
		int max = 0;
		for (int i = 0; i < n; i++) {
			int count = 0;
			for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			}
			if (count > max) {
				max = count;
			}
		}
		System.out.println(max);
	} main {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] uarr = new int[n];
		int[] darr = new int[n];
		for (int i = 0; i < n; i++) {
			uarr[i] = sc.nextInt();
		}
		for (int i = 0; i < n; i++) {
			darr[i] = sc.nextInt();
		}
		int max = 0;
		for (int i = 0; i < n; i++) {
			int count = 0;
			for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			}
			if (count > max) {
				max = count;
			}
		}
		System.out.println(max);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int[] uarr = new int[n]; uarr new int[n] n int[] darr = new int[n]; darr new int[n] n for (int i = 0; i < n; i++) {
			uarr[i] = sc.nextInt();
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			uarr[i] = sc.nextInt();
		} {
			uarr[i] = sc.nextInt();
		} uarr[i] = sc.nextInt() uarr[i] uarr i sc.nextInt() sc.nextInt sc for (int i = 0; i < n; i++) {
			darr[i] = sc.nextInt();
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			darr[i] = sc.nextInt();
		} {
			darr[i] = sc.nextInt();
		} darr[i] = sc.nextInt() darr[i] darr i sc.nextInt() sc.nextInt sc int max = 0; max 0 for (int i = 0; i < n; i++) {
			int count = 0;
			for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			}
			if (count > max) {
				max = count;
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			int count = 0;
			for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			}
			if (count > max) {
				max = count;
			}
		} {
			int count = 0;
			for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			}
			if (count > max) {
				max = count;
			}
		} int count = 0; count 0 for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			} int j = 0; int j = 0; j 0 j < n j n j++ j++ j {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			} {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			} if (j <= i) {
					count += uarr[j];
				} j <= i j i {
					count += uarr[j];
				} count += uarr[j] count uarr[j] uarr j if (j >= i) {
					count += darr[j];
				} j >= i j i {
					count += darr[j];
				} count += darr[j] count darr[j] darr j if (count > max) {
				max = count;
			} count > max count max {
				max = count;
			} max = count max count System.out.println(max) System.out.println System.out System System.out max String[] args args public class Main {

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] uarr = new int[n];
		int[] darr = new int[n];
		for (int i = 0; i < n; i++) {
			uarr[i] = sc.nextInt();
		}
		for (int i = 0; i < n; i++) {
			darr[i] = sc.nextInt();
		}
		int max = 0;
		for (int i = 0; i < n; i++) {
			int count = 0;
			for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			}
			if (count > max) {
				max = count;
			}
		}
		System.out.println(max);
	}
} public class Main {

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] uarr = new int[n];
		int[] darr = new int[n];
		for (int i = 0; i < n; i++) {
			uarr[i] = sc.nextInt();
		}
		for (int i = 0; i < n; i++) {
			darr[i] = sc.nextInt();
		}
		int max = 0;
		for (int i = 0; i < n; i++) {
			int count = 0;
			for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			}
			if (count > max) {
				max = count;
			}
		}
		System.out.println(max);
	}
} Main
import java.util.*;

public class Main {

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int[] uarr = new int[n];
		int[] darr = new int[n];
		for (int i = 0; i < n; i++) {
			uarr[i] = sc.nextInt();
		}
		for (int i = 0; i < n; i++) {
			darr[i] = sc.nextInt();
		}
		int max = 0;
		for (int i = 0; i < n; i++) {
			int count = 0;
			for (int j = 0; j < n; j++) {
				if (j <= i) {
					count += uarr[j];
				}
				if (j >= i) {
					count += darr[j];
				}
			}
			if (count > max) {
				max = count;
			}
		}
		System.out.println(max);
	}
}
