Problem lunchbox
User deepdapy
Submission Time 2026-04-22 20:18:50
Score 0
Max Time N/A
Max Memory N/A

Compile Error

lunchbox.cpp:2:1: error: ‘vector’ does not name a type
2 | vector<int> x(m);
| ^~~~~~
lunchbox.cpp:4:1: error: ‘cin’ does not name a type
4 | cin >> N >> m;
| ^~~
lunchbox.cpp:5:1: error: expected unqualified-id before ‘for’
5 | for (int i = 0; i < m; i++) {
| ^~~
lunchbox.cpp:5:17: error: ‘i’ does not name a type
5 | for (int i = 0; i < m; i++) {
| ^
lunchbox.cpp:5:24: error: ‘i’ does not name a type
5 | for (int i = 0; i < m; i++) {
| ^
lunchbox.cpp:9:5: error: expected constructor, destructor, or type conversion before ‘(’ token
9 | sort(x.begin(), x.end());
| ^
lunchbox.cpp:11:1: error: expected unqualified-id before ‘for’
11 | for (int i = 0; i < m; i++) {
| ^~~
lunchbox.cpp:11:17: error: ‘i’ does not name a type
11 | for (int i = 0; i < m; i++) {
|