| Problem | swords |
|---|---|
| User | shenshiqi |
| Submission Time | 2025-11-08 00:15:25 |
| Score | 0 |
| Max Time | N/A |
| Max Memory | N/A |
Owl Get a Life
swords.cpp: In function ‘int main()’:
swords.cpp:11:49: error: expected identifier before ‘&’ token
11 | sort(swords.begin(), swords.end(), [](auto &x, &y){
| ^
swords.cpp: In lambda function:
swords.cpp:12:20: error: request for member ‘first’ in ‘y’, which is of non-class type ‘int’
12 | if (x.first == y.first) return x.second < y.second;
| ^~~~~
swords.cpp:12:47: error: request for member ‘second’ in ‘y’, which is of non-class type ‘int’
12 | if (x.first == y.first) return x.second < y.second;
| ^~~~~~
swords.cpp:13:22: error: request for member ‘first’ in ‘y’, which is of non-class type ‘int’
13 | return x.first > y.first;
| ^~~~~
In file included from /usr/include/c++/9/bits/stl_algobase.h:71,
from /usr/include/c++/9/bits/specfun.h:45,