Problem firefighting
User IAmOcean
Submission Time 2022-12-28 19:12:18
Score 0
Max Time N/A
Max Memory N/A

Compile Error

firefighting.cpp: In function ‘std::vector<int> find_fire_stations(int, int, const std::vector<Road>&)’:
firefighting.cpp:46:37: error: ‘j’ was not declared in this scope
46 | bool is_close_a = any(abs(a - j) <= k for j in fire_stations);
| ^
firefighting.cpp:46:25: error: ‘any’ was not declared in this scope
46 | bool is_close_a = any(abs(a - j) <= k for j in fire_stations);
| ^~~
In file included from /usr/include/c++/9/algorithm:62,
from firefighting.cpp:3:
/usr/include/c++/9/bits/stl_algo.h: In instantiation of ‘void std::__insertion_sort(_RandomAccessIterator, _RandomAccessIterator, _Compare) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<const Road*, std::vector<Road> >; _Compare = __gnu_cxx::__ops::_Iter_comp_iter<bool (*)(const Road&, const Road&)>]’:
/usr/include/c++/9/bits/stl_algo.h:1890:25: