QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#572886#9308. World Cup_habiCompile Error//C++17494b2024-09-18 16:41:222024-09-18 16:41:23

Judging History

你现在查看的是最新测评结果

  • [2024-09-18 16:41:23]
  • 评测
  • [2024-09-18 16:41:22]
  • 提交

answer

#include<iostream>
#include<vector>
using namespace std;
int main()
{
	ios::sync_with_stdio(0);
	cin.tie(0);
	int t;cin>>t;
	while(t--)
	{
		int n=32;
		int cnt=0;
		vector<int>a(n);
		for(int i=0;i<n;i++)cin>>a[i];
		for(int i=1;i<n;i++)
		 if(a[i]>a[0]) cnt++;
		if(cnt>31-2) cout<<32<<endl;
		else if(cnt>31-6)cout<<16<<endl;
		else if(cnt>31-13)cout<<8<<endl;
		else if(cnt>31-13-13-1) cout<<4<<endl;
		else if(cnt>0) cout<<2<<endl;
		else cout<<1<<endl;
	return 0;
}

Details

answer.code: In function ‘int main()’:
answer.code:24:2: error: expected ‘}’ at end of input
   24 | }
      |  ^
answer.code:5:1: note: to match this ‘{’
    5 | {
      | ^