Problem exam
User meal
Submission Time 2024-11-04 20:55:46
Score 0
Max Time N/A
Max Memory N/A

Compile Error

exam.cpp: In function ‘int main()’:
exam.cpp:8:15: error: expected ‘;’ before ‘if’
8 | cin >> a >> b
| ^
| ;
9 | if (x == 1){
| ~~
exam.cpp:11:4: error: ‘else’ without a previous ‘if’
11 | } else {
| ^~~~
exam.cpp:12:3: error: ‘print’ was not declared in this scope; did you mean ‘printf’?
12 | print(a*b)
| ^~~~~
| printf
exam.cpp:14:10: error: expected ‘;’ before ‘}’ token
14 | return 0
| ^
| ;
15 | }
| ~