Compile Error
foo.cc: In function 'void solve()': foo.cc:11:18: error: 'AC' was not declared in this scope 11 | }else if(bob>AC | ^~ foo.cc:13:5: error: expected primary-expression before '}' token 13 | } | ^ foo.cc:12:27: error: expected ')' before '}' token 12 | cout<<"Bob"<<endl; | ^ | ) 13 | } | ~ foo.cc:11:13: note: to match this '(' 11 | }else if(bob>AC | ^ foo.cc:13:5: error: expected primary-expression before '}' token 13 | } | ^ foo.cc: At global scope: foo.cc:14:5: error: expected unqualified-id before 'else' 14 | else if(bob==alice){ | ^~~~ foo.cc:17:1: error: expected declaration before '}' token 17 | } | ^
Code
#include<bits/stdc++.h>
using namespace std;
#define ll long long
void solve(){
ll a,b,c,d,e,f;
cin>>a>>b>>c>>d>>e>>f;
ll alice = b-(a*c);
ll bob = e-(f*d);
if(alice>bob){
cout<<"Alice"<<endl;
}else if(bob>AC
cout<<"Bob"<<endl;
}
else if(bob==alice){
cout<<"Draw"<<endl;
}
}
int main(){
solve();
return 0;
}
Information
- Submit By
- Type
- Submission
- Problem
- P1177 Remainder Game
- Contest
- Intra LU IEEE Beginner Programming Contest
- Language
- C++17 (G++ 13.2.0)
- Submit At
- 2025-02-26 06:07:06
- Judged At
- 2025-02-26 06:07:06
- Judged By
- Score
- 0
- Total Time
- 0ms
- Peak Memory
- 0 Bytes