Problem 3nplus1
User Tez
Submission Time 2023-11-10 15:45:03
Score 0
Max Time N/A
Max Memory N/A

Compile Error

3nplus1.cpp: In function ‘int main()’:
3nplus1.cpp:7:12: error: expected ‘)’ before ‘if’
7 | while(n>=1
| ~ ^
| )
8 | if (n % 2 == 0){
| ~~
3nplus1.cpp:9:21: error: expected ‘;’ before ‘cout’
9 | printNumber = n/2
| ^
| ;
10 | cout << n << "";
| ~~~~
3nplus1.cpp: At global scope:
3nplus1.cpp:17:1: error: expected declaration before ‘}’ token
17 | }
| ^