#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 / manish soni tagore collage jai
my dear frd....
here some hapen.
#define swap(a,b) temp=a;a=b;b=temp;----------(1)
is was as function of swap two no;(but it is differnt frm
funtion.)
so
at i>j;
enter swap(i,j);
so jump at eq(n) ---(1) and call swap function'
and
temp=5;
i=10;
j=0;
you see three variable.
but it printf i,j to convert swap.
bcoz it have two arguments.
and print temp=0;
becoz temp have 0;
Is This Answer Correct ? | 0 Yes | 7 No |
Post New Answer View All Answers
what is ur strangth & weekness
An application package has been provided to you without any documents for the following application. The application needs to be tested. How will you proceed?
Give basis knowledge of web designing ...
Which is better oop or procedural?
Draw a flowchart to produce a printed list of all the students over the age of 20 in a class .The input records contains the name and age of students. Assume a sentinel value of 99 for the age field of the trailer record
What is sizeof c?
Tell us the use of fflush() function in c language?
What is the process to generate random numbers in c programming language?
What is the difference between void main and main in c?
What is build process in c?
What are operators in c?
What will be the outcome of the following conditional statement if the value of variable s is 10?
What is the scope of static variables in c language?
Is this program statement valid? INT = 10.50;
Why we use stdio h in c?