bryce1010模板

http://codeforces.com/gym/101810

#include <bits/stdc++.h>

using namespace std;
#define ll long long
const int MAXN=1010;
int a[MAXN<<1];
int main()
{ int t;
cin>>t;
int n;
while(t--)
{
cin>>n; for(int i=1;i<=2*n;i++)
{
cin>>a[i];
}
int maxsum=0;
for(int i=1;i<=n;i++)
{
maxsum=max(maxsum,a[i]+a[2*n-i+1]);
}
cout<<maxsum<<endl;
} return 0;
}
05-11 10:57