#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 / harish

it enters into swap function only when i>j.

but i contains 5 and j contains 10.

can u plz explain this

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are loops c?

604


Explain built-in function?

582


Is flag a keyword in c?

666


What should malloc(0) do?

603


Explain what is the difference between null and nul?

644






What are unions in c?

568


How can I avoid the abort, retry, fail messages?

643


Why is a semicolon (;) put at the end of every program statement?

612


What does c value mean?

612


how can use subset in c program and give more example

1487


What is assignment operator?

617


Explain can static variables be declared in a header file?

664


Lists the benefits of c programming language?

578


What are the 5 types of inheritance in c ++?

570


What is the best style for code layout in c?

621