2545.cpp (264B)
1 class Solution { 2 public: 3 vector<vector<int>> sortTheStudents(vector<vector<int>> &score, int k) { 4 sort(score.begin(), score.end(), 5 [k](const vector<int> &a, const vector<int> &b) { return a[k] >= b[k]; }); 6 return score; 7 } 8 };