boxes.cpp: In function 'long long int delivery(int, int, int, int*)':
boxes.cpp:2:14: error: request for member 'back' in 'p', which is of non-class type 'int*'
2 | return p.back()+min(p.back(), L-p.back());
| ^~~~
boxes.cpp:2:27: error: request for member 'back' in 'p', which is of non-class type 'int*'
2 | return p.back()+min(p.back(), L-p.back());
| ^~~~
boxes.cpp:2:39: error: request for member 'back' in 'p', which is of non-class type 'int*'
2 | return p.back()+min(p.back(), L-p.back());
| ^~~~
boxes.cpp:2:21: error: 'min' was not declared in this scope
2 | return p.back()+min(p.back(), L-p.back());
| ^~~
boxes.cpp:1:24: warning: unused parameter 'N' [-Wunused-parameter]
1 | long long delivery(int N, int K, int L, int p[]) {
| ~~~~^
boxes.cpp:1:31: warning: unused parameter 'K' [-Wunused-parameter]
1 | long long delivery(int N, int K, int L, int p[]) {
| ~~~~^