QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#589661#9313. Make MaxmikuloveCompile Error//C++20915b2024-09-25 19:25:112024-09-25 19:25:11

Judging History

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

  • [2024-09-25 19:25:11]
  • 评测
  • [2024-09-25 19:25:11]
  • 提交

answer

#include<bits/stdc++.h>
using namespace std;
#define int long long 
#define wil() int T;cin>>T;while(T--)
#define per(i,l,r) for(int i=l;i<=r;i++)
#define rep(i,r,l) for(int i=r;i>=l;i--)
#define all(it) it.begin(),it.end()
#define rall(it) it.rbegin(),it.rend()
#define PII pair<int,int> 
int mod = 998244353;
#define inf 0x3f3f3f3f
const int N = 2e2 + 5;

int a[N],b[N],c[N];

int n, m, q;

void sol(){
    cin >> n;
    while (n--) {
        int ans = 0;
        per(i,0,31){
        	cin>>a[i];
        	if(a[i]<=a[0]) ans++;
		}
        if (num == 32) cout<<"1"<<endl;
        else if (num >= 28) cout<<"2"endl;
        else if (num >= 14) cout<<"4"endl;
        else if (num >= 7) cout<<"8"endl;
        else if (num >= 3) cout<<"16"ednl;
        else cout<<"32"<<endl;
    }
}

signed main(){
	std::ios::sync_with_stdio(false);
	std::cin.tie(0);
//	wil()
	sol();
} 


Details

answer.code: In function ‘void sol()’:
answer.code:26:13: error: ‘num’ was not declared in this scope; did you mean ‘enum’?
   26 |         if (num == 32) cout<<"1"<<endl;
      |             ^~~
      |             enum
answer.code:27:35: error: unable to find string literal operator ‘operator""endl’ with ‘const char [2]’, ‘long unsigned int’ arguments
   27 |         else if (num >= 28) cout<<"2"endl;
      |                                   ^~~~~~~
answer.code:28:35: error: unable to find string literal operator ‘operator""endl’ with ‘const char [2]’, ‘long unsigned int’ arguments
   28 |         else if (num >= 14) cout<<"4"endl;
      |                                   ^~~~~~~
answer.code:29:34: error: unable to find string literal operator ‘operator""endl’ with ‘const char [2]’, ‘long unsigned int’ arguments
   29 |         else if (num >= 7) cout<<"8"endl;
      |                                  ^~~~~~~
answer.code:30:34: error: unable to find string literal operator ‘operator""ednl’ with ‘const char [3]’, ‘long unsigned int’ arguments
   30 |         else if (num >= 3) cout<<"16"ednl;
      |                                  ^~~~~~~~