Problem gotoschool
User blob
Submission Time 2023-11-14 13:17:54
Score 0
Max Time N/A
Max Memory N/A

Compile Error

gotoschool.cpp: In function ‘int main()’:
gotoschool.cpp:9:34: error: expected ‘;’ before ‘}’ token
9 | students.push_back({i+1,count})
| ^
| ;
10 | }
| ~
gotoschool.cpp:11:22: error: expected primary-expression before ‘]’ token
11 | sort(students.begin[], students.end[],[](const auto& a, const auto&b){
| ^
gotoschool.cpp:11:38: error: expected primary-expression before ‘]’ token
11 | sort(students.begin[], students.end[],[](const auto& a, const auto&b){
| ^
gotoschool.cpp: In lambda function:
gotoschool.cpp:13:30: error: ‘students’ is not captured
13 | for (const auto& student : students){
| ^~~~~~~~
gotoschool.cpp:11:41: note: the lambda has no capture-default
11 | sort(students.begin[