Problem exam
User Alexis10
Submission Time 2023-11-08 13:19:56
Score 0
Max Time N/A
Max Memory N/A

Compile Error

exam.cpp: In function ‘int main()’:
exam.cpp:7:8: error: expected ‘;’ before ‘if’
7 | cin>>x
| ^
| ;
8 | if (x==1) {
| ~~
exam.cpp:11:3: error: ‘else’ without a previous ‘if’
11 | else if (x==2) {
| ^~~~
exam.cpp:16:10: error: expected ‘}’ at end of input
16 | return 0;
| ^
exam.cpp:3:12: note: to match this ‘{’
3 | int main() {
| ^