#include<iostream> using namespace std; int shortQuikTest(char * v ,int left ,int right) { if(left>right) { return -1 ; } int i=left; int j=right; char key=*(v+left); while(i<j) { while(i<j&&key<=*(v+j)) { j--; } *(v+i)=*(v+j); while(i<j&&key>=*(v+i)) { i++; } *(v+j)=*(v+i); } *(v+i)=key; shortQuikTest( v,left,i-1); shortQuikTest( v,i+1,right); return 0; }