Sorting a list of a custom type

前端 未结 3 670

I want to have a stl list of objects where each object contains two int\'s. Afterwards I want to sort the list with stl::sort after the value of th

3条回答
  •  既然无缘
    2020-11-30 09:33

    std::list::sort has a one-argument form, with the first argument being the comparison function.

提交回复
热议问题