books.cpp: In function 'long long int minimum_walk(std::vector<int>, int)':
books.cpp:16:12: warning: unused variable 'i' [-Wunused-variable]
16 | for (auto&i : p) visited.push_back(0), maxis.push_back(-1);
| ^
books.cpp:7:33: warning: comparison of integer expressions of different signedness: 'll' {aka 'long long int'} and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
7 | #define FOR(i,x,y) for(ll i=x; i<y; i++)
......
18 | FOR(i,0,p.size()){
| ~~~~~~~~~~~~
books.cpp:18:2: note: in expansion of macro 'FOR'
18 | FOR(i,0,p.size()){
| ^~~
books.cpp:7:33: warning: comparison of integer expressions of different signedness: 'll' {aka 'long long int'} and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
7 | #define FOR(i,x,y) for(ll i=x; i<y; i++)
......
40 | FOR(i,0,p.size()){
| ~~~~~~~~~~~~
books.cpp:40:2: note: in expansion of macro 'FOR'
40 | FOR(i,0,p.size()){
| ^~~
books.cpp:44:13: warning: comparison of integer expressions of different signedness: 'll' {aka 'long long int'} and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
44 | while (cur < p.size()-1){
| ~~~~^~~~~~~~~~~~