/ Published in: C
pls hlp
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
#include <stdlib.h> #include <stdio.h> int main() { int arrayLength; int i; for(i=0; i<arrayLength; i++) { } int countOfComparators=(arrayLength*arrayLength-1)/2; int temp; int comparatorIterations=0; for(comparatorIterations<arrayLength; comparatorIterations++;) { if(numberCount[comparatorIterations] > numberCount[comparatorIterations+1]) { temp=numberCount[comparatorIterations+1]; numberCount[comparatorIterations+1]=numberCount[comparatorIterations]; numberCount[comparatorIterations]=temp; } } int loopNum; for(loopNum=0; loopNum<arrayLength; loopNum++) { } return 0; }