There are two methods of sorting .
1 Bubble sorting
2 Internal sorting
Following is the procedure of internal sortting
int i=0,j=0,temp=0;
for(i=0 ; i < aa.length() ; i++){
for(j=i+1; j<=aa.length() ;j++){
if(aa[i] > aa[j]){
temp=aa[i];
aa[i] = aa[j];
aa[j] = temp;
}
}
}
Note :
Not sure aboout the method of aa.length() or aa.length