#include <stdio.h>
int main(void)
{
int a,b,c;
printf("Enter values of a,b,c:");
scanf("%d %d %d",a,b,c);
printf("\nDescending order of the numbers entered:");
/*Test for Biggest Number*/
if((a>b)&&(a>c))
printf("%d",a);
else if((b>a)&&(b>c))
printf("%d",b);
else if((c>a)&&(c>b))
printf("%d",c);
/*Test for Second Biggest Number*/
if((a>b&&a<c)||(a<b&&a>c))
printf("%d",a);
else if((b>a&&b<c)||(b<a&&b>c))
printf("%d",b);
else if((c>a&&c<b)||(c<a&&c>b))
printf("%d",c);
/*Test for Smallest Number*/
if((a<b)&&(a<c))
printf("%d",a);
else if((b<a)&&(b<c))
printf("%d",b);
else if((c<a)&&(c<b))
printf("%d",c);
return 0;
}
this is a c program in which 3 numbers are entered and the program prints the in descending order. i compiled the program and the ran the program.after entering the three numbers the program would just crash. is there something wrong with my code or do i have to add something?