Problem cinema
User JustKitkat
Submission Time 2024-11-28 08:59:53
Score 0
Max Time N/A
Max Memory N/A

Compile Error

cinema.cpp: In function ‘int main()’:
cinema.cpp:23:7: error: redeclaration of ‘long long int r1’
23 | int r1=*s.upper_bound(x)--;
| ^~
cinema.cpp:22:7: note: ‘long long int r1’ previously declared here
22 | int r1=*s.upper_bound(x);
| ^~
cinema.cpp:25:6: error: ‘r2’ was not declared in this scope; did you mean ‘r1’?
25 | if(r2-r1-1>=k)t+=(r2-r1-k)*p;
| ^~
| r1
cinema.cpp:27:6: error: ‘r2’ was not declared in this scope; did you mean ‘r1’?
27 | if(r2-x-1>=k)t-=(r2-x-k)*p;
| ^~
| r1