how to swap the variables without using temp and operators
Answer / santhosh
int a, b;
a = 10;
b = 20;
a = a + b;
//a=30
b = a - b;
a = a - b;
Console.WriteLine("a={0},b={1}", a, b);
Console.ReadLine();
| Is This Answer Correct ? | 10 Yes | 2 No |
In what situation factory design patterns,DAO design patterns,singleton design patterns should be applied.?
What is encapsulation with real life example?
write a program in c++ to overload the function add (s1,s2) where s1 and s2 are integers and floating point values.
Write a program to accept a number and to print numbers in pyramid format? for eg:for a no. 5 1 212 32123 4321234 543212345
write a program to print * * * * * *
write a code for this:trailer recordId contains a value other than 99, then the file must error with the reason ‘Invalid RECORD_ID’(User Defined Exception).
what type of question are asked in thoughtworks pair programming round ?
Why do we use class in oops?
Which is the parameter that is added to every non-static member function when it is called?
What is encapsulation in ict?
Why multiple inheritance is not possible?
How to hide the base class functionality in Inheritance?