#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; #define REP(i,m,n) for(int i=(int)(m) ; i < (int) (n) ; ++i ) #define rep(i,n) REP(i,0,n) using ll = long long; const int inf=1e9+7; const ll longinf=1LL<<60 ; const ll mod=1e9+7 ; #define pai 3.141592653589793238462643383279 int main(){ int n, s, t; cin >> n >> s >> t; s--; t--; ll a[n]; ll sum=0; rep(i, n){ cin >> a[i]; sum+=a[i]; } vectortmp; if(s=n) s-=n; if(s>t) t+=n; for(int i=s; i<=(t-s)/2+s; i++){ tmp.push_back(a[i%n]); } ll nyan = 0; rep(i, (n+1)/2){ nyan+=tmp[i]; } ll ans=nyan; //for(auto k: tmp){ //cout << k << "o " << endl; //} for(int i=(n+1)/2; i