swap two number wthout using third variable

Answer Posted / jvhariharan

void main()
{
int a=10,b=20;
a=a+b;
b=a-b;
a=a-b;
}

Is This Answer Correct ?    24 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

You are given some denominations of coins in an array (int denom[])and infinite supply of all of them. Given an amount (int amount), find the minimum number of coins required to get the exact amount. What is the method called?

596


what is difference between kpo and it industry? that is in terms of work, package etc

1531


how do i create my own exception class which will restrict IO exception?

2297


WHAT IS MAIN IMPORTANT THING IN SOFTWARE?

1718


what is the current salary package in India for a lamp programmer

1870






what is the difference between rename and label

1808


What is SAP TAO? · Which Version you are using? · What is the Latest Version in SAP TAO? · What are the Advantages in SAP TAO? · What are the Patches required for SAP TAO? · What is BPT? · Difference between BPT & SAP TAO? · Which Framework using for SAP TAO? · What is CBASE? · What is the SAP TAO Architecture? · What are the Prerequisites for SAP TAO? · SAP Solution Manager Mandatory for SAP TAO 1.0? · SAP Solution Manager Mandatory for SAP TAO 2.X? · What is UI Scanner? · What is Inspector? · How many ways to Create a components using TAO 1.0? · How many ways to Create a components using TAO 2.x? · Which service pack required for SAP TAO 2.7? · What is Import/Export? · What is Consolidate?

2380


why we use abstract in awt?

1554


how pseudo column works?

1711


what is radio button? Plz show code this! how will select radio buttons to go next window Forms? Supose o radio button1 o radio button2 o radio button3 o radio button4 how will coding this? Plz explain this!

2899


differences between qtp10.0 and 11.0 ?

1808


what is the diff bw sql direct and jdbc update can't we do select and updating operation in sql direct

1676


Given an array all of whose elements are positive numbers, find the maximum sum of a subsequence with the constraint that no 2 numbers in the sequence should be adjacent in the array. So 3 2 7 10 should return 13 (sum of 3 and 10) or 3 2 5 10 7 should return 15 (sum of 3, 5 and 7)

752


when we use mantis? how learn mantis?

1683


where is available in this mantis toturials?

1603