Okay, I'm studying about the bubble sorting thing. I am able to do it, but the post that guide me, didn't explain one part.
Can someone explain me the indicated part like explaining it to a beginner?
Because, I can't really get what is really happening in this part of the source code.
Please, explain the indicated part, thanks!
Code:
#include<stdio.h>
#include<conio.h>
int main()
{
int a[5], b, c, d;
clrscr();
printf("ENTER 5 NO \n\n");
for(b=0;b<5;b++)
scanf("%d", &a[b]);
/*This part, help me with this*/
for(b=0;b<5;b++)
{
for(c=b+1;c<5++)
{
if(a>a[c])
{
d=a;
a=a[c];
a[c]=d;
}
}
}
/*Until here*/
for(b=0;b<5;b++)
{
printf("\n%d\n", a[b]);
}
getche();
}