
import java.util.*;

public class Main{
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int[][] s = new int[5][110];
		int n = scan.nextInt();
		for(int i = 1; i <= n; ++i) {
			s[1][i] = scan.nextInt();
		}
		for(int i = 1; i <= n; ++i) {
			s[2][i] = scan.nextInt();
		}
		int sum = 0,sum2,sum3 = 0;
		for(int i = 1; i <= n; ++i) {
			sum += s[1][i];
			sum2 = sum;
			for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			}
			if(sum > sum3) {
				sum3 = sum;
			}
			sum = sum2;
			
		}
		System.out.println(sum3);
				
		
	}
} import java.util.*; util.* java public class Main{
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int[][] s = new int[5][110];
		int n = scan.nextInt();
		for(int i = 1; i <= n; ++i) {
			s[1][i] = scan.nextInt();
		}
		for(int i = 1; i <= n; ++i) {
			s[2][i] = scan.nextInt();
		}
		int sum = 0,sum2,sum3 = 0;
		for(int i = 1; i <= n; ++i) {
			sum += s[1][i];
			sum2 = sum;
			for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			}
			if(sum > sum3) {
				sum3 = sum;
			}
			sum = sum2;
			
		}
		System.out.println(sum3);
				
		
	}
} Main public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int[][] s = new int[5][110];
		int n = scan.nextInt();
		for(int i = 1; i <= n; ++i) {
			s[1][i] = scan.nextInt();
		}
		for(int i = 1; i <= n; ++i) {
			s[2][i] = scan.nextInt();
		}
		int sum = 0,sum2,sum3 = 0;
		for(int i = 1; i <= n; ++i) {
			sum += s[1][i];
			sum2 = sum;
			for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			}
			if(sum > sum3) {
				sum3 = sum;
			}
			sum = sum2;
			
		}
		System.out.println(sum3);
				
		
	} main {
		Scanner scan = new Scanner(System.in);
		int[][] s = new int[5][110];
		int n = scan.nextInt();
		for(int i = 1; i <= n; ++i) {
			s[1][i] = scan.nextInt();
		}
		for(int i = 1; i <= n; ++i) {
			s[2][i] = scan.nextInt();
		}
		int sum = 0,sum2,sum3 = 0;
		for(int i = 1; i <= n; ++i) {
			sum += s[1][i];
			sum2 = sum;
			for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			}
			if(sum > sum3) {
				sum3 = sum;
			}
			sum = sum2;
			
		}
		System.out.println(sum3);
				
		
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int[][] s = new int[5][110]; s new int[5][110] 5 110 int n = scan.nextInt(); n scan.nextInt() scan.nextInt scan for(int i = 1; i <= n; ++i) {
			s[1][i] = scan.nextInt();
		} int i = 1; int i = 1; i 1 i <= n i n ++i ++i i {
			s[1][i] = scan.nextInt();
		} {
			s[1][i] = scan.nextInt();
		} s[1][i] = scan.nextInt() s[1][i] s[1] s 1 i scan.nextInt() scan.nextInt scan for(int i = 1; i <= n; ++i) {
			s[2][i] = scan.nextInt();
		} int i = 1; int i = 1; i 1 i <= n i n ++i ++i i {
			s[2][i] = scan.nextInt();
		} {
			s[2][i] = scan.nextInt();
		} s[2][i] = scan.nextInt() s[2][i] s[2] s 2 i scan.nextInt() scan.nextInt scan int sum = 0 sum 0 sum2 sum2 sum3 = 0; sum3 0 for(int i = 1; i <= n; ++i) {
			sum += s[1][i];
			sum2 = sum;
			for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			}
			if(sum > sum3) {
				sum3 = sum;
			}
			sum = sum2;
			
		} int i = 1; int i = 1; i 1 i <= n i n ++i ++i i {
			sum += s[1][i];
			sum2 = sum;
			for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			}
			if(sum > sum3) {
				sum3 = sum;
			}
			sum = sum2;
			
		} {
			sum += s[1][i];
			sum2 = sum;
			for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			}
			if(sum > sum3) {
				sum3 = sum;
			}
			sum = sum2;
			
		} sum += s[1][i] sum s[1][i] s[1] s 1 i sum2 = sum sum2 sum for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			} int j = i; int j = i; j i j <= n j n ++j ++j j {
				sum += s[2][j];
			} {
				sum += s[2][j];
			} sum += s[2][j] sum s[2][j] s[2] s 2 j if(sum > sum3) {
				sum3 = sum;
			} sum > sum3 sum sum3 {
				sum3 = sum;
			} sum3 = sum sum3 sum sum = sum2 sum sum2 System.out.println(sum3) System.out.println System.out System System.out sum3 String[] args args public class Main{
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int[][] s = new int[5][110];
		int n = scan.nextInt();
		for(int i = 1; i <= n; ++i) {
			s[1][i] = scan.nextInt();
		}
		for(int i = 1; i <= n; ++i) {
			s[2][i] = scan.nextInt();
		}
		int sum = 0,sum2,sum3 = 0;
		for(int i = 1; i <= n; ++i) {
			sum += s[1][i];
			sum2 = sum;
			for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			}
			if(sum > sum3) {
				sum3 = sum;
			}
			sum = sum2;
			
		}
		System.out.println(sum3);
				
		
	}
} public class Main{
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int[][] s = new int[5][110];
		int n = scan.nextInt();
		for(int i = 1; i <= n; ++i) {
			s[1][i] = scan.nextInt();
		}
		for(int i = 1; i <= n; ++i) {
			s[2][i] = scan.nextInt();
		}
		int sum = 0,sum2,sum3 = 0;
		for(int i = 1; i <= n; ++i) {
			sum += s[1][i];
			sum2 = sum;
			for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			}
			if(sum > sum3) {
				sum3 = sum;
			}
			sum = sum2;
			
		}
		System.out.println(sum3);
				
		
	}
} Main

import java.util.*;

public class Main{
	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		int[][] s = new int[5][110];
		int n = scan.nextInt();
		for(int i = 1; i <= n; ++i) {
			s[1][i] = scan.nextInt();
		}
		for(int i = 1; i <= n; ++i) {
			s[2][i] = scan.nextInt();
		}
		int sum = 0,sum2,sum3 = 0;
		for(int i = 1; i <= n; ++i) {
			sum += s[1][i];
			sum2 = sum;
			for(int j = i;j <= n ; ++j) {
				sum += s[2][j];
			}
			if(sum > sum3) {
				sum3 = sum;
			}
			sum = sum2;
			
		}
		System.out.println(sum3);
				
		
	}
}
