struct mypair{ int id; int time; mypair(int a, int b):id(a), time(b){;} bool operator<(const mypair other) const{ return (this->time < other.time); } }; bool compare(mypair& a, mypair& b){ return a.time > b.time; } class Solution { public: /*...