Write a program to interchange two variables without using
the third variable?

Answer Posted / saravanan j (srm universi

you can apply it on any language?!

x = x xor y
y = x xor y
x = x xor y

* 1 year ago

Source(s):
Self Expierince

Is This Answer Correct ?    18 Yes 12 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of bitwise operator?

683


What is a dynamic array in c?

587


which type of aspect you want from the student.

1699


Using which language Test cases are added in .ptu file of RTRT unit testing???

3581


What is context in c?

536






What is an lvalue in c?

690


Explain indirection?

637


Tell us something about keyword 'auto'.

659


What is this infamous null pointer, anyway?

607


can anyone suggest some site name..where i can get some good data structure puzzles???

1643


What does main () mean in c?

609


What is difference between structure and union?

593


How can a string be converted to a number?

512


Find the second largest element in an array with minimum no of comparisons and give the minimum no of comparisons needed on an array of size N to do the same.

713


Explain the difference between null pointer and void pointer.

663