i^=j;
j^=i;
i^=j;
value of i,j



i^=j; j^=i; i^=j; value of i,j..

Answer / xyz

this code snippet will swap the value of i and j
This code works same as
i=i+j;
j=i-j;
i=i-j;

Is This Answer Correct ?    2 Yes 1 No

Post New Answer

More OOPS Interview Questions

Write a program to multiply 3x3 matrics

1 Answers  


Write a C++ program without using any loop (if, for, while etc) to print prime numbers from 1 to 100 and 100 to 1 (Do not use 200 print statements!!!)

0 Answers   HCL,


Why is static class not inherited?

0 Answers  


Pls...could any one tell me that whether we can access the public data memeber of a class from another class with in the same program. Awaiting for your response Thanku

4 Answers  


write knight tour problem which is present in datastructure

0 Answers  






what is the sylabus for priliminaries?

0 Answers  


Out of 4 concepts, which 3 C++ Follow?

1 Answers   TCS,


What are generic functions and generic classes?

5 Answers  


I am DeePu sotware engineer working with EMC corporation ,recently I had attended mcafee interview . Their questions were at heights of stupidity , I don't know what they want , I am a developer with 4 year experienced .I am listing the questions asked 1:What is the flag in g++ to avoid structure padding 2:In wht order parameters are passed to stack 3:How you will edit code segment of an exe

1 Answers  


What are the fields of vtable

1 Answers   Mphasis,


how can we design a magic square in c++?or suggest me the basic idea of it.

3 Answers  


write string class as your own class in java without using any built-in function

0 Answers  


Categories