Thursday, 8 February 2018

C Program to find greatest of three numbers

Today we will discuss about C program to find Largest Number among three numbers.
To solve this problem we use Nested if...else statement.

C Program to find greatest of three numbers


//wap to find largest number form three numbers

#include <stdio.h>
#incule<conio.h>
int a, b, c;
Printf("\n enter a, b, c");
Scanf("%d, %d, %d" &a, &b, &c);
if(a>b&&a>c);
printf("greatest number is=%d", a);
else if (b>c)

printf("greatest number is =%d",b);
else
printf("greatest number is =%d",c);
getch();
}
Share This
Previous Post
Next Post

Admin and author of BestBCANotes. Complted master degree in Computer Science.

0 comments: