
算法
半缘君
一个立志于想在IT界有一席之地的人!
展开
-
冒泡排序
package bubblesort; public class Init { //交换 void Swap(int a[],int x,int y){ int temp = a[x]; a[x] = a[y]; a[y] = temp; } //打印出结�? void Print(int a[]){ for(int原创 2012-03-10 21:14:16 · 544 阅读 · 0 评论 -
选择排序
package select; public class Select { //交换 void Swap(int a[],int x,int y){ int temp = a[x]; a[x] = a[y]; a[y] = temp; } //打印出 void Print(int a[]){ for(i原创 2012-03-10 22:41:10 · 432 阅读 · 0 评论