Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR C

how to sort assending in c

for (i = 0; i < n; ++i){
   for (j = i + 1; j < n; ++j){
      if (num[i] > num[j]){
         a = num[i];
         num[i] = num[j];
         num[j] = a;
      }
   }
}
Source by www.tutorialspoint.com #
 
PREVIOUS NEXT
Tagged: #sort #assending
ADD COMMENT
Topic
Name
5+3 =