Problem duckhunt12
User ax17le
Submission Time 2025-06-17 11:19:43
Score 0
Max Time N/A
Max Memory N/A

Compile Error

duckhunt12.cpp: In function ‘int main()’:
duckhunt12.cpp:24:9: error: ‘poB’ was not declared in this scope; did you mean ‘posB’?
24 | if ((poB == N and dirB == 1) || (posB == 1 and dirB == -1)
| ^~~
| posB
duckhunt12.cpp:26:4: error: expected primary-expression before ‘else’
26 | else
| ^~~~
duckhunt12.cpp:25:15: error: expected ‘)’ before ‘else’
25 | dirB*= -1;
| ^
| )
26 | else
| ~~~~
duckhunt12.cpp:24:7: note: to match this ‘(’
24 | if ((poB == N and dirB == 1) || (posB == 1 and dirB == -1)
| ^