Problem flamethrower
User Yifei1234
Submission Time 2023-03-08 17:20:15
Score 0
Max Time N/A
Max Memory N/A

Compile Error

flamethrower.cpp: In function ‘int main()’:
flamethrower.cpp:6:10: error: expected ‘;’ before ‘int’
6 | cin>>n>>k
| ^
| ;
7 | int best=0;
| ~~~
flamethrower.cpp:10:15: error: expected ‘;’ before ‘<=’ token
10 | for (int j=i,j<=i+(k-1);j++)
| ^~
| ;
flamethrower.cpp:10:15: error: expected primary-expression before ‘<=’ token
10 | for (int j=i,j<=i+(k-1);j++)
| ^~
flamethrower.cpp:11:1: error: expected primary-expression before ‘}’ token
11 | }
| ^
flamethrower.cpp:12:1: error: ‘best’ was not declared in this scope
12 | best max(best,counter);
| ^~~~