Problem flamethrower
User wongethan8192
Submission Time 2023-02-10 17:46:09
Score 0
Max Time N/A
Max Memory N/A

Compile Error

flamethrower.cpp: In function ‘int main()’:
flamethrower.cpp:7:1: error: expected initializer before ‘for’
7 | for(int x=0;x<a;x++)cin>>arr[x];
| ^~~
flamethrower.cpp:7:13: error: ‘x’ was not declared in this scope
7 | for(int x=0;x<a;x++)cin>>arr[x];
| ^
flamethrower.cpp:11:1: error: ‘z’ was not declared in this scope
11 | z[y]=sum;}
| ^
flamethrower.cpp:12:5: error: overloaded function with no contextual type information
12 | max=0;
| ^
flamethrower.cpp:13:28: error: ‘z’ was not declared in this scope
13 | for(int b=0;b<a-b+1;b++)if(z[b]>max)max=z[b];cout<<max;}
| ^
flamethrower.cpp:13:50: error: no match for ‘operator<<’ (operand types are ‘std::ostream’ {aka ‘std::basic_ostream<char>’} and ‘<unresolved overloaded function type>’)
13 | for(int b=0;b<a-b+1;b++)if(z[b]>max)max=z[b];cout<