/* A program to compare three numbers and display the biggest number*/
#include
int main ()
{
int x,y,z;
printf ("Enter three numbers:");
scanf("%d %d %d",&x,&y,&z);
if((x>y)&&(x>z))
{
printf("the biggest number is %d",x);
}
else if((y>x)&&(y>z))
{
printf("the biggest number is %d",y);
}
else
{
printf("the biggest number is %d",z);
}
return 0;
}
OUTPUT:

No comments:
Post a Comment
If you have any doubt, please ask in the comment section.