#include<stdio.h>
#include<conio.h>
# define swap(a,b) temp=a; a=b; b=temp;
void main( )
{
int i, j, temp;
i=5;
j=10;
temp=0;
if( i > j)
swap( i, j );
printf( "%d %d %d", i, j, temp);
}

Answer Posted / ashish rajvanshi

My dear frnds its a simple question
here the code of macro inserted in the program at the time of preprocessing and then the calculation will performed.
and then it will be calculated.

void main()
{
int i,j, temp;
i=5;
j=10;
temp=0;
if(i>j)
temp=a;
a=b;
b=temp;
printf("%d %d %d" , i , j , temp);
}

for further detail contect at(ashish.raj.mrt@gmail.com)

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

write a c program to print the next of a particular no without using the arithmetic operator or looping statements?

3180


What is the purpose of clrscr () printf () and getch ()?

591


I heard that you have to include stdio.h before calling printf. Why?

582


Which is better malloc or calloc?

645


Give differences between - new and malloc() , delete and free() ?

604






How can you increase the size of a dynamically allocated array?

636


What is a scope resolution operator in c?

745


What is the difference between abs() and fabs() functions?

599


List some applications of c programming language?

544


Differentiate between Macro and ordinary definition.

722


Synonymous with pointer array a) character array b) ragged array c) multiple array d) none

613


What is #include called?

565


What is the difference between scanf and fscanf?

658


What is p in text message?

536


What is scope and lifetime of a variable in c?

570