提交时间:2023-02-02 14:04:54
运行 ID: 68087
#include <bits/stdc++.h> using namespace std; int small,sesmall,num,c,n; int main(){ cin>>c; while(c--){ small=101; sesmall=101; cin>>n; while(n--){ cin>>num; if(num<small) small=num; if(num>small&&num<sesmall) sesmall=num; } if(sesmall<=101) cout<<sesmall; else cout<<"NO"; } return 0; }