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 descending order as below
int[] array = new int[] { 3, 1, 4, 5, 2 };
Array.Sort<int>( array );
Array.Reverse( array );
Now,the question is that.Is there any better way to do the same in c#?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…