Better way to sort array in descending order

后端 未结 7 2161
伪装坚强ぢ
伪装坚强ぢ 2020-12-01 09:54

I have a array of int which I have to sort by descending.

Since I did not find any method to sort the array in descending order.Currently I am sorting the array in

相关标签:
7条回答
  • 2020-12-01 11:00

    You may specify a comparer(IComparer implementation) as a parameter in Array.Sort, the order of sorting actually depends on comparer. The default comparer is used in ascending sorting

    0 讨论(0)
提交回复
热议问题