选择排序
摘要:
1 template 2 void SelectSort(T *a, int nCount) 3 { 4 int nMinIndex = 0;//标识最小项的索引 5 T temp; 6 for(int i=0;ia[j])12 {13 nMinIndex = j;14 }15 }16 if(nMinIndex!=i){17 temp = a[nMinIndex];18 a[nMinIndex] = a[i]... 阅读全文
posted @ 2013-07-10 00:50
时光飞逝~
阅读(114)
评论(0)
推荐(0)
浙公网安备 33010602011771号