Problem wrongreverse
User fwuffysleepycat
Submission Time 2026-04-15 17:49:59
Score 0
Max Time N/A
Max Memory N/A

Compile Error

wrongreverse.cpp: In function ‘int32_t main()’:
wrongreverse.cpp:12:5: error: expected ‘,’ or ‘;’ before ‘for’
12 | for(int i = 0; i < n; i++){
| ^~~
wrongreverse.cpp:12:20: error: ‘i’ was not declared in this scope
12 | for(int i = 0; i < n; i++){
| ^
wrongreverse.cpp:16:14: error: no match for ‘operator>>’ (operand types are ‘std::ostream’ {aka ‘std::basic_ostream<char>’} and ‘long long int’)
16 | cout >> a[1];
| ~~~~ ^~ ~~~~
| | |
| | long long int
| std::ostream {aka std::basic_ostream<char>}
wrongreverse.cpp:16:14: note: candidate: ‘operator>>(int, long long int)’ <built-in>
16 | cout >> a[1];
| ~~~~~^~~~~~~
wrongreverse.cpp:16:14: note: no known conversion for argument 1 from ‘std::ostream’ {aka ‘std::basic_ostream<char>’