提交时间:2022-04-10 11:23:11
运行 ID: 48163
#include <bits/stdc++.h> using namespace std; int n,game[101]; int main() { cin>>n; for(int i=1;i<=n;i++) cin>>game[i]; if(n%2) cout<<max(game[1],game[n])<<endl; else cout<<min(game[1],game[n])<<endl; return 0; }