#include <bits/stdc++.h>
using namespace std;
long long dp[2][100005];
int h[2][100005];
long long maxx[2];
int main() {
  int n, i, j;
  scanf("%d", &n);
  for (i = 0; i < 2; i++)
    for (j = 1; j <= n; j++) scanf("%d", &h[i][j]);
  for (j = 1; j <= n; j++) {
    for (i = 0; i < 2; i++) dp[i][j] = h[i][j] + maxx[(i + 1) % 2];
    maxx[0] = max(maxx[0], dp[0][j]);
    maxx[1] = max(maxx[1], dp[1][j]);
  }
  printf("%I64d", max(maxx[1], maxx[0]));
  return 0;
}
