Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Find greatest of two numbers using macro

Answer Posted / banavathvishnu

#include<stdio.h>
#include<conio.h>

#define Greatest(X,Y) X>Y?X:Y

int main()
{
int x,y;
scanf("%d %d",&x,&y);
printf("%d",Greatest(x,y));
getch();
}

Is This Answer Correct ?    91 Yes 10 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is pointer to pointer in c language?

1143


Describe how arrays can be passed to a user defined function

1292


Why #include is used in c language?

1048


how to execute a program using if else condition and the output should enter number and the number is odd only...

2296


What are the differences between Structures and Arrays?

1211


What are the types of functions in c?

984


What is the equivalent code of the following statement in WHILE LOOP format?

1303


How can I invoke another program or command and trap its output?

1095


What is sizeof array in c?

1053


What is the difference between arrays and pointers?

1126


What is the size of structure pointer in c?

1065


How can I find out if there are characters available for reading?

1109


What are pointers?

1105


What are the types of bitwise operator?

1107


What does printf does?

1243