/* In-place Histogram Sort by Marion McCoskey December 11, 1998 */ // 12345678901234567 char buf[]="ABEDEBEDDBEBDBDEB";//buffer with data to sort void main(){ unsigned hstS[5]; //sort histogram unsigned hstR[5]; //reference histogram unsigned ind; //index variable char tmp0; //first temporary storage char tmp1; //second temporary storage unsigned pnt; //pointer unsigned ePnt; //empty pointer, points to a region with an empty // storage element unsigned siz=sizeof(buf)-1;//size of the sort buffer minus the zero // termination for(ind=0;ind<5;ind++) //Clear the sort histogram. hstS[ind]=0; for(ind=0;ind