How do we swap or interchange any 2 numbers without using
Temporary variable...Anybody can pls answer it.. Thanks in
Advance
Answer Posted / raghuram.a
int x,y;
x =x-y;
y =y+x;
x =y-x;
or
int x,y;
x=x^y;
y=x^y;
x=x^y;
| Is This Answer Correct ? | 11 Yes | 7 No |
Post New Answer View All Answers
What will be the outcome of the following conditional statement if the value of variable s is 10?
What are the advantages of c language?
What are the types of variables in c?
What is FIFO?
Can we declare a function inside a function in c?
Explain how do you view the path?
What does c mean in standard form?
What are structures and unions? State differencves between them.
code for quick sort?
What is difference between static and global variable in c?
Hi how many types of software editions are there and their difference (like home editions, enterprise, standard etc) can u please help me
What is a program flowchart?
write a program to find out prime number using sieve case?
Explain 'far' and 'near' pointers in c.
Is array a primitive data type in c?