//package com.company;

import java.io.*;
import java.util.*;

public class Main {
    static long TIME_START, TIME_END;
    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);
//        Scanner sc = new Scanner(new FileInputStream("Test.in"));
        PrintWriter pw = new PrintWriter(System.out);
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.out"));
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.in"));

        Runtime runtime = Runtime.getRuntime();
        long usedMemoryBefore = runtime.totalMemory() - runtime.freeMemory();
        TIME_START = System.currentTimeMillis();
        Task t = new Task();
        t.solve(sc, pw);
        TIME_END = System.currentTimeMillis();
        long usedMemoryAfter = runtime.totalMemory() - runtime.freeMemory();
        pw.close();
//        System.out.println("Memory increased:" + (usedMemoryAfter-usedMemoryBefore) / 1000000 );
//        System.out.println("Time used: " + (TIME_END - TIME_START) + ".");

    }


    public static class Task {

        public void solve(Scanner sc, PrintWriter pw) throws IOException {
            int n = sc.nextInt();
            int[] prefix = new int[n];
            int[] suffix = new int[n];
            int[] a = new int[n];
            int[] b = new int[n];
            for (int i = 0; i < n; i++) {
                a[i] = sc.nextInt();
            }
            for (int i = 0; i < n; i++) {
                b[i] = sc.nextInt();
            }
            prefix[0] = a[0];
            suffix[n - 1] = b[n - 1];
            for (int i = 1; i < n; i++) {
                prefix[i] = a[i] + prefix[i - 1];
            }
            for (int i = n - 2; i >= 0; i--) {
                suffix[i] = b[i] + suffix[i + 1];
            }
            int max = 0;
            for (int i = 0; i < n; i++) {
                max = Math.max(max, prefix[i] + suffix[i]);
            }
            pw.println(max);
        }

    }



    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s){  br = new BufferedReader(new InputStreamReader(s));}

        public Scanner(FileReader s) throws FileNotFoundException {br = new BufferedReader(s);}

        public String next() throws IOException
        {
            while (st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine());
            return st.nextToken();
        }

        public int nextInt() throws IOException {return Integer.parseInt(next());}

        public long nextLong() throws IOException {return Long.parseLong(next());}

        public String nextLine() throws IOException {return br.readLine();}

        public double nextDouble() throws IOException { return Double.parseDouble(next()); }

        public boolean ready() throws IOException {return br.ready();}
    }
} import java.io.*; io.* java import java.util.*; util.* java public class Main {
    static long TIME_START, TIME_END;
    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);
//        Scanner sc = new Scanner(new FileInputStream("Test.in"));
        PrintWriter pw = new PrintWriter(System.out);
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.out"));
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.in"));

        Runtime runtime = Runtime.getRuntime();
        long usedMemoryBefore = runtime.totalMemory() - runtime.freeMemory();
        TIME_START = System.currentTimeMillis();
        Task t = new Task();
        t.solve(sc, pw);
        TIME_END = System.currentTimeMillis();
        long usedMemoryAfter = runtime.totalMemory() - runtime.freeMemory();
        pw.close();
//        System.out.println("Memory increased:" + (usedMemoryAfter-usedMemoryBefore) / 1000000 );
//        System.out.println("Time used: " + (TIME_END - TIME_START) + ".");

    }


    public static class Task {

        public void solve(Scanner sc, PrintWriter pw) throws IOException {
            int n = sc.nextInt();
            int[] prefix = new int[n];
            int[] suffix = new int[n];
            int[] a = new int[n];
            int[] b = new int[n];
            for (int i = 0; i < n; i++) {
                a[i] = sc.nextInt();
            }
            for (int i = 0; i < n; i++) {
                b[i] = sc.nextInt();
            }
            prefix[0] = a[0];
            suffix[n - 1] = b[n - 1];
            for (int i = 1; i < n; i++) {
                prefix[i] = a[i] + prefix[i - 1];
            }
            for (int i = n - 2; i >= 0; i--) {
                suffix[i] = b[i] + suffix[i + 1];
            }
            int max = 0;
            for (int i = 0; i < n; i++) {
                max = Math.max(max, prefix[i] + suffix[i]);
            }
            pw.println(max);
        }

    }



    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s){  br = new BufferedReader(new InputStreamReader(s));}

        public Scanner(FileReader s) throws FileNotFoundException {br = new BufferedReader(s);}

        public String next() throws IOException
        {
            while (st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine());
            return st.nextToken();
        }

        public int nextInt() throws IOException {return Integer.parseInt(next());}

        public long nextLong() throws IOException {return Long.parseLong(next());}

        public String nextLine() throws IOException {return br.readLine();}

        public double nextDouble() throws IOException { return Double.parseDouble(next()); }

        public boolean ready() throws IOException {return br.ready();}
    }
} Main static long TIME_START TIME_START TIME_END; TIME_END public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);
//        Scanner sc = new Scanner(new FileInputStream("Test.in"));
        PrintWriter pw = new PrintWriter(System.out);
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.out"));
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.in"));

        Runtime runtime = Runtime.getRuntime();
        long usedMemoryBefore = runtime.totalMemory() - runtime.freeMemory();
        TIME_START = System.currentTimeMillis();
        Task t = new Task();
        t.solve(sc, pw);
        TIME_END = System.currentTimeMillis();
        long usedMemoryAfter = runtime.totalMemory() - runtime.freeMemory();
        pw.close();
//        System.out.println("Memory increased:" + (usedMemoryAfter-usedMemoryBefore) / 1000000 );
//        System.out.println("Time used: " + (TIME_END - TIME_START) + ".");

    } main {
        Scanner sc = new Scanner(System.in);
//        Scanner sc = new Scanner(new FileInputStream("Test.in"));
        PrintWriter pw = new PrintWriter(System.out);
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.out"));
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.in"));

        Runtime runtime = Runtime.getRuntime();
        long usedMemoryBefore = runtime.totalMemory() - runtime.freeMemory();
        TIME_START = System.currentTimeMillis();
        Task t = new Task();
        t.solve(sc, pw);
        TIME_END = System.currentTimeMillis();
        long usedMemoryAfter = runtime.totalMemory() - runtime.freeMemory();
        pw.close();
//        System.out.println("Memory increased:" + (usedMemoryAfter-usedMemoryBefore) / 1000000 );
//        System.out.println("Time used: " + (TIME_END - TIME_START) + ".");

    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) PrintWriter pw = new PrintWriter(System.out); pw new PrintWriter(System.out) Runtime runtime = Runtime.getRuntime(); runtime Runtime.getRuntime() Runtime.getRuntime Runtime long usedMemoryBefore = runtime.totalMemory() - runtime.freeMemory(); usedMemoryBefore runtime.totalMemory() - runtime.freeMemory() runtime.totalMemory() runtime.totalMemory runtime runtime.freeMemory() runtime.freeMemory runtime TIME_START = System.currentTimeMillis() TIME_START System.currentTimeMillis() System.currentTimeMillis System Task t = new Task(); t new Task() t.solve(sc, pw) t.solve t sc pw TIME_END = System.currentTimeMillis() TIME_END System.currentTimeMillis() System.currentTimeMillis System long usedMemoryAfter = runtime.totalMemory() - runtime.freeMemory(); usedMemoryAfter runtime.totalMemory() - runtime.freeMemory() runtime.totalMemory() runtime.totalMemory runtime runtime.freeMemory() runtime.freeMemory runtime pw.close() pw.close pw String[] args args public static class Task {

        public void solve(Scanner sc, PrintWriter pw) throws IOException {
            int n = sc.nextInt();
            int[] prefix = new int[n];
            int[] suffix = new int[n];
            int[] a = new int[n];
            int[] b = new int[n];
            for (int i = 0; i < n; i++) {
                a[i] = sc.nextInt();
            }
            for (int i = 0; i < n; i++) {
                b[i] = sc.nextInt();
            }
            prefix[0] = a[0];
            suffix[n - 1] = b[n - 1];
            for (int i = 1; i < n; i++) {
                prefix[i] = a[i] + prefix[i - 1];
            }
            for (int i = n - 2; i >= 0; i--) {
                suffix[i] = b[i] + suffix[i + 1];
            }
            int max = 0;
            for (int i = 0; i < n; i++) {
                max = Math.max(max, prefix[i] + suffix[i]);
            }
            pw.println(max);
        }

    } Task public void solve(Scanner sc, PrintWriter pw) throws IOException {
            int n = sc.nextInt();
            int[] prefix = new int[n];
            int[] suffix = new int[n];
            int[] a = new int[n];
            int[] b = new int[n];
            for (int i = 0; i < n; i++) {
                a[i] = sc.nextInt();
            }
            for (int i = 0; i < n; i++) {
                b[i] = sc.nextInt();
            }
            prefix[0] = a[0];
            suffix[n - 1] = b[n - 1];
            for (int i = 1; i < n; i++) {
                prefix[i] = a[i] + prefix[i - 1];
            }
            for (int i = n - 2; i >= 0; i--) {
                suffix[i] = b[i] + suffix[i + 1];
            }
            int max = 0;
            for (int i = 0; i < n; i++) {
                max = Math.max(max, prefix[i] + suffix[i]);
            }
            pw.println(max);
        } solve {
            int n = sc.nextInt();
            int[] prefix = new int[n];
            int[] suffix = new int[n];
            int[] a = new int[n];
            int[] b = new int[n];
            for (int i = 0; i < n; i++) {
                a[i] = sc.nextInt();
            }
            for (int i = 0; i < n; i++) {
                b[i] = sc.nextInt();
            }
            prefix[0] = a[0];
            suffix[n - 1] = b[n - 1];
            for (int i = 1; i < n; i++) {
                prefix[i] = a[i] + prefix[i - 1];
            }
            for (int i = n - 2; i >= 0; i--) {
                suffix[i] = b[i] + suffix[i + 1];
            }
            int max = 0;
            for (int i = 0; i < n; i++) {
                max = Math.max(max, prefix[i] + suffix[i]);
            }
            pw.println(max);
        } int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int[] prefix = new int[n]; prefix new int[n] n int[] suffix = new int[n]; suffix new int[n] n 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] = sc.nextInt();
            } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
                a[i] = sc.nextInt();
            } {
                a[i] = sc.nextInt();
            } a[i] = sc.nextInt() a[i] a i sc.nextInt() sc.nextInt sc for (int i = 0; i < n; i++) {
                b[i] = sc.nextInt();
            } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
                b[i] = sc.nextInt();
            } {
                b[i] = sc.nextInt();
            } b[i] = sc.nextInt() b[i] b i sc.nextInt() sc.nextInt sc prefix[0] = a[0] prefix[0] prefix 0 a[0] a 0 suffix[n - 1] = b[n - 1] suffix[n - 1] suffix n - 1 n 1 b[n - 1] b n - 1 n 1 for (int i = 1; i < n; i++) {
                prefix[i] = a[i] + prefix[i - 1];
            } int i = 1; int i = 1; i 1 i < n i n i++ i++ i {
                prefix[i] = a[i] + prefix[i - 1];
            } {
                prefix[i] = a[i] + prefix[i - 1];
            } prefix[i] = a[i] + prefix[i - 1] prefix[i] prefix i a[i] + prefix[i - 1] a[i] a i prefix[i - 1] prefix i - 1 i 1 for (int i = n - 2; i >= 0; i--) {
                suffix[i] = b[i] + suffix[i + 1];
            } int i = n - 2; int i = n - 2; i n - 2 n 2 i >= 0 i 0 i-- i-- i {
                suffix[i] = b[i] + suffix[i + 1];
            } {
                suffix[i] = b[i] + suffix[i + 1];
            } suffix[i] = b[i] + suffix[i + 1] suffix[i] suffix i b[i] + suffix[i + 1] b[i] b i suffix[i + 1] suffix i + 1 i 1 int max = 0; max 0 for (int i = 0; i < n; i++) {
                max = Math.max(max, prefix[i] + suffix[i]);
            } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
                max = Math.max(max, prefix[i] + suffix[i]);
            } {
                max = Math.max(max, prefix[i] + suffix[i]);
            } max = Math.max(max, prefix[i] + suffix[i]) max Math.max(max, prefix[i] + suffix[i]) Math.max Math max prefix[i] + suffix[i] prefix[i] prefix i suffix[i] suffix i pw.println(max) pw.println pw max Scanner sc sc PrintWriter pw pw static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s){  br = new BufferedReader(new InputStreamReader(s));}

        public Scanner(FileReader s) throws FileNotFoundException {br = new BufferedReader(s);}

        public String next() throws IOException
        {
            while (st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine());
            return st.nextToken();
        }

        public int nextInt() throws IOException {return Integer.parseInt(next());}

        public long nextLong() throws IOException {return Long.parseLong(next());}

        public String nextLine() throws IOException {return br.readLine();}

        public double nextDouble() throws IOException { return Double.parseDouble(next()); }

        public boolean ready() throws IOException {return br.ready();}
    } Scanner StringTokenizer st; st BufferedReader br; br public Scanner(InputStream s){  br = new BufferedReader(new InputStreamReader(s));} Scanner {  br = new BufferedReader(new InputStreamReader(s));} br = new BufferedReader(new InputStreamReader(s)) br new BufferedReader(new InputStreamReader(s)) InputStream s s public Scanner(FileReader s) throws FileNotFoundException {br = new BufferedReader(s);} Scanner {br = new BufferedReader(s);} br = new BufferedReader(s) br new BufferedReader(s) FileReader s s public String next() throws IOException
        {
            while (st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine());
            return st.nextToken();
        } next {
            while (st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine());
            return st.nextToken();
        } while (st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine()); st == null || !st.hasMoreTokens() st == null st null !st.hasMoreTokens() st.hasMoreTokens() st.hasMoreTokens st st = new StringTokenizer(br.readLine()) st new StringTokenizer(br.readLine()) return st.nextToken(); st.nextToken() st.nextToken st public int nextInt() throws IOException {return Integer.parseInt(next());} nextInt {return Integer.parseInt(next());} return Integer.parseInt(next()); Integer.parseInt(next()) Integer.parseInt Integer next() next public long nextLong() throws IOException {return Long.parseLong(next());} nextLong {return Long.parseLong(next());} return Long.parseLong(next()); Long.parseLong(next()) Long.parseLong Long next() next public String nextLine() throws IOException {return br.readLine();} nextLine {return br.readLine();} return br.readLine(); br.readLine() br.readLine br public double nextDouble() throws IOException { return Double.parseDouble(next()); } nextDouble { return Double.parseDouble(next()); } return Double.parseDouble(next()); Double.parseDouble(next()) Double.parseDouble Double next() next public boolean ready() throws IOException {return br.ready();} ready {return br.ready();} return br.ready(); br.ready() br.ready br public class Main {
    static long TIME_START, TIME_END;
    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);
//        Scanner sc = new Scanner(new FileInputStream("Test.in"));
        PrintWriter pw = new PrintWriter(System.out);
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.out"));
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.in"));

        Runtime runtime = Runtime.getRuntime();
        long usedMemoryBefore = runtime.totalMemory() - runtime.freeMemory();
        TIME_START = System.currentTimeMillis();
        Task t = new Task();
        t.solve(sc, pw);
        TIME_END = System.currentTimeMillis();
        long usedMemoryAfter = runtime.totalMemory() - runtime.freeMemory();
        pw.close();
//        System.out.println("Memory increased:" + (usedMemoryAfter-usedMemoryBefore) / 1000000 );
//        System.out.println("Time used: " + (TIME_END - TIME_START) + ".");

    }


    public static class Task {

        public void solve(Scanner sc, PrintWriter pw) throws IOException {
            int n = sc.nextInt();
            int[] prefix = new int[n];
            int[] suffix = new int[n];
            int[] a = new int[n];
            int[] b = new int[n];
            for (int i = 0; i < n; i++) {
                a[i] = sc.nextInt();
            }
            for (int i = 0; i < n; i++) {
                b[i] = sc.nextInt();
            }
            prefix[0] = a[0];
            suffix[n - 1] = b[n - 1];
            for (int i = 1; i < n; i++) {
                prefix[i] = a[i] + prefix[i - 1];
            }
            for (int i = n - 2; i >= 0; i--) {
                suffix[i] = b[i] + suffix[i + 1];
            }
            int max = 0;
            for (int i = 0; i < n; i++) {
                max = Math.max(max, prefix[i] + suffix[i]);
            }
            pw.println(max);
        }

    }



    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s){  br = new BufferedReader(new InputStreamReader(s));}

        public Scanner(FileReader s) throws FileNotFoundException {br = new BufferedReader(s);}

        public String next() throws IOException
        {
            while (st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine());
            return st.nextToken();
        }

        public int nextInt() throws IOException {return Integer.parseInt(next());}

        public long nextLong() throws IOException {return Long.parseLong(next());}

        public String nextLine() throws IOException {return br.readLine();}

        public double nextDouble() throws IOException { return Double.parseDouble(next()); }

        public boolean ready() throws IOException {return br.ready();}
    }
} public class Main {
    static long TIME_START, TIME_END;
    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);
//        Scanner sc = new Scanner(new FileInputStream("Test.in"));
        PrintWriter pw = new PrintWriter(System.out);
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.out"));
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.in"));

        Runtime runtime = Runtime.getRuntime();
        long usedMemoryBefore = runtime.totalMemory() - runtime.freeMemory();
        TIME_START = System.currentTimeMillis();
        Task t = new Task();
        t.solve(sc, pw);
        TIME_END = System.currentTimeMillis();
        long usedMemoryAfter = runtime.totalMemory() - runtime.freeMemory();
        pw.close();
//        System.out.println("Memory increased:" + (usedMemoryAfter-usedMemoryBefore) / 1000000 );
//        System.out.println("Time used: " + (TIME_END - TIME_START) + ".");

    }


    public static class Task {

        public void solve(Scanner sc, PrintWriter pw) throws IOException {
            int n = sc.nextInt();
            int[] prefix = new int[n];
            int[] suffix = new int[n];
            int[] a = new int[n];
            int[] b = new int[n];
            for (int i = 0; i < n; i++) {
                a[i] = sc.nextInt();
            }
            for (int i = 0; i < n; i++) {
                b[i] = sc.nextInt();
            }
            prefix[0] = a[0];
            suffix[n - 1] = b[n - 1];
            for (int i = 1; i < n; i++) {
                prefix[i] = a[i] + prefix[i - 1];
            }
            for (int i = n - 2; i >= 0; i--) {
                suffix[i] = b[i] + suffix[i + 1];
            }
            int max = 0;
            for (int i = 0; i < n; i++) {
                max = Math.max(max, prefix[i] + suffix[i]);
            }
            pw.println(max);
        }

    }



    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s){  br = new BufferedReader(new InputStreamReader(s));}

        public Scanner(FileReader s) throws FileNotFoundException {br = new BufferedReader(s);}

        public String next() throws IOException
        {
            while (st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine());
            return st.nextToken();
        }

        public int nextInt() throws IOException {return Integer.parseInt(next());}

        public long nextLong() throws IOException {return Long.parseLong(next());}

        public String nextLine() throws IOException {return br.readLine();}

        public double nextDouble() throws IOException { return Double.parseDouble(next()); }

        public boolean ready() throws IOException {return br.ready();}
    }
} Main
//package com.company;

import java.io.*;
import java.util.*;

public class Main {
    static long TIME_START, TIME_END;
    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(System.in);
//        Scanner sc = new Scanner(new FileInputStream("Test.in"));
        PrintWriter pw = new PrintWriter(System.out);
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.out"));
//        PrintWriter pw = new PrintWriter(new FileOutputStream("Test.in"));

        Runtime runtime = Runtime.getRuntime();
        long usedMemoryBefore = runtime.totalMemory() - runtime.freeMemory();
        TIME_START = System.currentTimeMillis();
        Task t = new Task();
        t.solve(sc, pw);
        TIME_END = System.currentTimeMillis();
        long usedMemoryAfter = runtime.totalMemory() - runtime.freeMemory();
        pw.close();
//        System.out.println("Memory increased:" + (usedMemoryAfter-usedMemoryBefore) / 1000000 );
//        System.out.println("Time used: " + (TIME_END - TIME_START) + ".");

    }


    public static class Task {

        public void solve(Scanner sc, PrintWriter pw) throws IOException {
            int n = sc.nextInt();
            int[] prefix = new int[n];
            int[] suffix = new int[n];
            int[] a = new int[n];
            int[] b = new int[n];
            for (int i = 0; i < n; i++) {
                a[i] = sc.nextInt();
            }
            for (int i = 0; i < n; i++) {
                b[i] = sc.nextInt();
            }
            prefix[0] = a[0];
            suffix[n - 1] = b[n - 1];
            for (int i = 1; i < n; i++) {
                prefix[i] = a[i] + prefix[i - 1];
            }
            for (int i = n - 2; i >= 0; i--) {
                suffix[i] = b[i] + suffix[i + 1];
            }
            int max = 0;
            for (int i = 0; i < n; i++) {
                max = Math.max(max, prefix[i] + suffix[i]);
            }
            pw.println(max);
        }

    }



    static class Scanner {
        StringTokenizer st;
        BufferedReader br;

        public Scanner(InputStream s){  br = new BufferedReader(new InputStreamReader(s));}

        public Scanner(FileReader s) throws FileNotFoundException {br = new BufferedReader(s);}

        public String next() throws IOException
        {
            while (st == null || !st.hasMoreTokens())
                st = new StringTokenizer(br.readLine());
            return st.nextToken();
        }

        public int nextInt() throws IOException {return Integer.parseInt(next());}

        public long nextLong() throws IOException {return Long.parseLong(next());}

        public String nextLine() throws IOException {return br.readLine();}

        public double nextDouble() throws IOException { return Double.parseDouble(next()); }

        public boolean ready() throws IOException {return br.ready();}
    }
}
