Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

swap 2 variables without using 3 rd variable???

Answer Posted / guest

Ex:
1.
A=20,B=10
A=A-B=20-10=10
B=A+B=10+10=20
A=B-A=20-10=10

2.
A=6,B=4
A=A-B=6-4=2
B=A+B=2+4=6
A=B-A=6-2=4

The above logic works if A>B. If B>A:

B=6, A=4
B=B-A=6-4=2
A=A+B=4+2=6
B=A-B=6-2=4

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Hi, i am looking job in perfomance testing using Loadrunner can any body help me a project in any domine plz(Usah) chs_29@rediffmail.com

2011


If you are handling a product testing and if there are around 100 test cases and in them few test cases are failed then at the end of the day how will you treat whether the product is pass/fail.? consider the failed test cases are in functional requirements.

1981


When should you opt for manual testing over automation testing?

1183


How to do manual testing of a E-insurance project (end to end process)

3302


Test approach to windows update?

2249


how do u manage scripts in winrunner when you application is changing frequently?

1908


Please send any one latest 3+ years of experience testing tools resumes my mail id is krishnavenimodaliar26@gmail.com

3285


What is the test case?

1073


Easiest way to write test cases? How i can learn writing the test cases?

1416


what is dib format?

1892


Tell me the SRS based review,brs based review

2178


Describe your personal software development process.

2612


Hi All. How can we write negative test cases for Logout Operation ? Please place the answer with a few details and if possible add some related object properties. "A tester exposes his/her ability not only by words he/she also proof it by work"

2937


what is test scenario and test condition?

1981


What is an entry criteria?

1111