Problem 3nplus1
User earthyeet
Submission Time 2025-07-29 11:50:27
Score 0
Max Time N/A
Max Memory N/A

Compile Error

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) {
| ^