| Problem | buyingcandy |
|---|---|
| User | estkn |
| Submission Time | 2026-11-10 00:16:40 |
| Score | 0 |
| Max Time | N/A |
| Max Memory | N/A |
Owl Get a Life
buyingcandy.cpp: In function ‘int main()’:
buyingcandy.cpp:17:12: error: request for member ‘begin’ in ‘p’, which is of non-class type ‘int [n]’
17 | sort(p.begin(), p.end());
| ^~~~~
buyingcandy.cpp:17:23: error: request for member ‘end’ in ‘p’, which is of non-class type ‘int [n]’
17 | sort(p.begin(), p.end());
| ^~~
buyingcandy.cpp:24:31: error: expected ‘)’ before ‘{’ token
24 | for (int i = 0; i < n; i++{
| ~ ^
| )
buyingcandy.cpp:31:21: error: expected ‘;’ before ‘}’ token
31 | pq.pop()
| ^
| ;
32 | }
| ~