Problem | 3nplus1 |
---|---|
User | earthyeet |
Submission Time | 2025-07-29 11:50:10 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
3nplus1.cpp: In function ‘int main()’:
3nplus1.cpp:11:11: error: expected ‘;’ before ‘}’ token
11 | cout << x
| ^
| ;
12 | }
| ~
3nplus1.cpp: In function ‘int calcu(int)’:
3nplus1.cpp:16:9: error: expected ‘;’ before ‘}’ token
16 | x /= 2
| ^
| ;
17 | } else {
| ~
3nplus1.cpp:18:16: error: expected ‘;’ before ‘return’
18 | x = (x*3) + 1
| ^
| ;
19 | return x
| ~~~~~~
3nplus1.cpp:20:1: error: expected ‘}’ at end of input
20 | }
| ^
3nplus1.cpp:14:18: note: to match this ‘{’
14 | int calcu(int x) {
| ^