Problem 3nplus1
User Achyuth
Submission Time 2026-11-02 11:53:01
Score 0
Max Time N/A
Max Memory N/A

Compile Error

3nplus1.cpp: In function ‘int main()’:
3nplus1.cpp:9:28: error: expected primary-expression before ‘,’ token
9 | cout << n/2 << , ' ';
| ^
3nplus1.cpp:10:17: error: expected ‘;’ before ‘}’ token
10 | n/=2
| ^
| ;
11 | } else {
| ~
3nplus1.cpp:12:20: error: expected primary-expression before ‘,’ token
12 | cout <<, 3*n + 1 , ' ';
| ^
3nplus1.cpp:13:23: error: expected ‘;’ before ‘}’ token
13 | n= 3*n + 1
| ^
| ;
14 | }
| ~
3nplus1.cpp:16:1: error: expected ‘}’ at end of input
16 | }
| ^
3nplus1.cpp:4:14: note: to match this ‘{’
4 | signed main(){
| ^