Problem | evenorodd |
---|---|
User | CX |
Submission Time | 2024-06-26 15:53:28 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
evenorodd.cpp:4:5: error: cannot declare ‘::main’ to be a global variable
4 | int main
| ^~~~
evenorodd.cpp:6:2: error: expected primary-expression before ‘int’
6 | int x;
| ^~~
evenorodd.cpp:6:2: error: expected ‘}’ before ‘int’
evenorodd.cpp:5:1: note: to match this ‘{’
5 | {
| ^
evenorodd.cpp:7:2: error: ‘cin’ does not name a type; did you mean ‘sin’?
7 | cin >> x;
| ^~~
| sin
evenorodd.cpp:8:2: error: expected unqualified-id before ‘if’
8 | if (x % 2==0)
| ^~
evenorodd.cpp:12:2: error: expected unqualified-id before ‘else’
12 | else
| ^~~~
evenorodd.cpp:14:2: error: expected declaration before ‘}’ token
14 | }
| ^
evenorodd.cpp:15:2: error: expected unqualified-id before ‘return’
15 | return 0;
| ^~~~~~
evenorodd.cpp:16:1: error: expected declaration before ‘}’ token
16 | }
| ^