Problem wonhee
User jerrielchangjiebin
Submission Time 2024-12-28 10:52:53
Score 0
Max Time N/A
Max Memory N/A

Compile Error

wonhee.cpp: In lambda function:
wonhee.cpp:22:17: error: ‘function’ was not declared in this scope
22 | function<bool(int, int)> can_escape =
| ^~~~~~~~
wonhee.cpp:4:1: note: ‘std::function’ is defined in header ‘<functional>’; did you forget to ‘#include <functional>’?
3 | #include <queue>
+++ |+#include <functional>
4 |
wonhee.cpp:22:39: error: expression list treated as compound expression in functional cast [-fpermissive]
22 | function<bool(int, int)> can_escape =
| ^
wonhee.cpp:22:26: error: expected primary-expression before ‘bool’
22 | function<bool(int, int)> can_escape =
| ^~~~
wonhee.cpp:39:22: error: ‘can_escape’ was not declared in this scope
39 | if (!can_escape(r, c)) {
| ^~~~