Problem duckhunt5
User Yichen
Submission Time 2025-08-19 14:23:38
Score 0
Max Time N/A
Max Memory N/A

Compile Error

duckhunt5.cpp: In function ‘int main()’:
duckhunt5.cpp:8:23: error: found ‘:’ in nested-name-specifier, expected ‘::’
8 | for (int i = 0; i < n: i++) {
| ^
| ::
duckhunt5.cpp:8:22: error: ‘n’ is not a class, namespace, or enumeration
8 | for (int i = 0; i < n: i++) {
| ^
duckhunt5.cpp:22:1: error: expected primary-expression before ‘}’ token
22 | }
| ^
duckhunt5.cpp:21:3: error: expected ‘;’ before ‘}’ token
21 | }
| ^
| ;
22 | }
| ~
duckhunt5.cpp:22:1: error: expected primary-expression before ‘}’ token
22 | }
| ^
duckhunt5.cpp:21:3: error: expected ‘)’ before ‘}’ token
21 | }
| ^
| )
22 | }
| ~
duckhunt5.cpp:8:6: note: to match this ‘(’
8 | for (int i = 0; i < n: i++) {
| ^
duckhunt5.cpp:22:1: error: exp