Friday, March 28, 2014

C Program to find out greatest of two numbers

C Program to find out greatest of two numbers

#include<stdio.h>
#include<conio.h>
void main()
{
int a,b;
clrscr();
printf ("Enter any two number\n");
scanf("%d\n%d",&a,&b);
if (a>b)
printf("%d is greater than %d",a,b);
else
printf("%d is greater than %d",b,a);
getch();
}

No comments:

Post a Comment