Compile Error
foo.cc: In function 'int main()': foo.cc:17:27: error: expected '}' at end of input 17 | cout<<operation<<endl; | ^ foo.cc:3:11: note: to match this '{' 3 | int main(){ | ^
Code
#include<iostream>
using namespace std;
int main(){
int N;
cin>>N;
int operation=0;
while(N>0){
if(N%3==0){
N=N-3;
operation++;
}
else{
N=N-2;
operation++;
}
}
cout<<operation<<endl;
Information
- Submit By
- Type
- Submission
- Problem
- P1106 too easy or three easy
- Contest
- Brain Booster #6
- Language
- C++17 (G++ 13.2.0)
- Submit At
- 2024-10-03 16:01:11
- Judged At
- 2024-11-11 02:49:27
- Judged By
- Score
- 0
- Total Time
- 0ms
- Peak Memory
- 0 Bytes