面试基础,快速排序和二分排序c++实现
#include
#include
using namespace std;
void showInt(int e){
cout<<e<<" ";
}
// 遍历数组
void printArray(int *a,int length){
for_each(a,a+length,showInt);
cout<<endl;
}
//交换值函数
void swap(int &a,int &b)
原创
2014-09-30 21:56:53 ·
573 阅读 ·
0 评论