how to swap two numbers with out using temp variable

Answer Posted / arundhati

a^=b^=a^=b;

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Assume an array of structure is in order by studentID field of the record, where student IDs go from 101 to 500. Write the most efficient pseudocode algorithm you can to find the record with a specific studentID if every single student ID from 101 to 500 is used and the array has 400 elements. Write the most efficient pseudocode algorithm you can to find a record with a studentID near the end of the IDs, say in the range from 450 to 500, if not every single student ID in the range of 101 to 500 is used and the array size is only 300

1783


What are the advantages of c++? Explain

588


What is a .h file c++?

526


What is data binding in c++?

499


What are the 3 levels of programming languages?

528






C is to C++ as 1 is to a) What the heck b) 2 c) 10

633


Why cout is used in c++?

557


What are the differences between new and malloc?

625


Is c++ an oop?

581


What is the basic structure of c++ program?

562


How long it will take to learn c++?

608


What are keywords in c++?

592


When should you use global variables?

623


Can I have a reference as a data member of a class? If yes, then how do I initialise it?

698


What are separators in c++?

619