#define swap1(a,b) a=a+b;b=a-b;a=a-b;
main()
{
int x=5,y=10;
swap1(x,y);
printf("%d %d\n",x,y);
swap2(x,y);
printf("%d %d\n",x,y);
}
int swap2(int a,int b)
{
int temp;
temp=a;
b=a;
a=temp;
return;
}
what are the outputs?
Answer Posted / mannucse
10 5
5 10
| Is This Answer Correct ? | 9 Yes | 10 No |
Post New Answer View All Answers
Explain what is the advantage of a random access file?
What are pointers really good for, anyway?
An organised method of depicting the use of an area of computer memory used to signify the uses for different parts of the memory a) swap b) extended memory c) memory map d) all of the above
What does the message "automatic aggregate intialization is an ansi feature" mean?
What is pointer to pointer in c language?
What are loops in c?
Why is not a pointer null after calling free? How unsafe is it to use (assign, compare) a pointer value after it is been freed?
What is LINKED LIST? How can you access the last element in a linked list?
Discuss the function of conditional operator, size of operator and comma operator with examples.
What are the modifiers available in c programming language?
Can you explain the four storage classes in C?
What functions are used in dynamic memory allocation in c?
find out largest elemant of diagonalmatrix
what is the c source code for the below output? 5555555555 4444 4444 333 333 22 22 1 1 22 22 333 333 4444 4444 5555555555
What is getche() function?