Problem 3nplus1
User meowmeow
Submission Time 2023-06-01 20:19:01
Score 0
Max Time N/A
Max Memory N/A

Compile Error

3nplus1.cpp:1:2: error: invalid preprocessing directive #insert; did you mean #assert?
1 | #insert <iostream>
| ^~~~~~
| assert
3nplus1.cpp: In function ‘int main()’:
3nplus1.cpp:5:8: error: ‘cin’ was not declared in this scope
5 | int n; cin >> n;
| ^~~
3nplus1.cpp:1:1: note: ‘std::cin’ is defined in header ‘<iostream>’; did you forget to ‘#include <iostream>’?
+++ |+#include <iostream>
1 | #insert <iostream>
3nplus1.cpp:11:1: error: ‘cout’ was not declared in this scope
11 | cout << n << " ";}
| ^~~~
3nplus1.cpp:11:1: note: ‘std::cout’ is defined in header ‘<iostream>’; did you forget to ‘#include <iostream>’?
3nplus1.cpp:12:16: error: ‘cout’ was not declared in this scope
12 | else {n = n/2; cout << n << " ";}}}
| ^~~~
3nplus1.cpp:12:16: note: ‘std::cout’ is defined in header ‘<iostr