C# List

C# List

常用的范型链表数据结构

Sort

list类自带的排序函数
Sort应该是两个数进行比较,可能是冒泡排序。

//index 起始索引, count 从index开始圈定范围 ,实现Icomparer接口
public void Sort(int index, int count, IComparer<T> comparer);

//Comparison是C#预定义的泛型委托 
//public delegate int Comparison<in T>(T x, T y);
//返回值 大于1 表示 x与y交换位置 
public void Sort(Comparison<T> comparison);

public void Sort(IComparer<T> comparer);

public void Sort();
原文地址:https://www.cnblogs.com/tangpeng97/p/14542911.html