Skip to content

Commit a4f2fba

Browse files
authored
greatest number
Program to find the greatest of two number
1 parent c5c05c2 commit a4f2fba

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

gretest

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
#include<stdio.h>
2+
#include<conio.h>
3+
void main()
4+
{
5+
6+
int n1,n2,sum;
7+
clrscr();
8+
9+
printf("\nEnter 1st number : ");
10+
scanf("%d",&n1);
11+
12+
printf("\nEnter 2nd number : ");
13+
scanf("%d",&n2);
14+
15+
if(n1 > n2)
16+
printf("\n1st number is greatest.");
17+
else
18+
printf("\n2nd number is greatest.");
19+
20+
getch();
21+
}

0 commit comments

Comments
 (0)