C programme to find greatest number from given three numbers
/*C programme to find greatest number from
given three numbers */
#include <stdio.h>
#include <conio.h>
void main()
{
int
a,b,c;
printf("Enter
three number : ");
scanf("%d
%d %d",&a,&b,&c);
if
(a>b) {
if
(b>c) {
printf("\n %d is greatest",a);
}
}
else if
(b>a) {
if
(b>c) {
printf("\n %d is greatest",b);
}
else {
printf("\n %d is greatest",c);
}
}
getch();
}
0 Comments