Program to sort the marks in asending order


#include
void sort(int m, int x[]);
main()
{

int i;
int marks[5]={40, 90, 73, 81, 35};
clrscr();
printf("Marks before sorting\n");
for(i=0; i<5; i="0;" i="1;" j="1;j<="m-1;j++)">=x[j]
{
temp=x[j-1];
x[j-1]=x[j];
x[j]=temp;
}
}
}
}




No comments:

Post a Comment