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...

wat are the two methods for swapping two numbers without
using temp variable??

Answer Posted / vijayakumar kanagasabai

main()
{
int a=4;b=6;
printf("Before swapping: a=%d, b=%d",a,b);
a=a+b;
b=a-b;
a=a-b;
printf("After swapping: a=%d, b=%d",a,b);
}

Is This Answer Correct ?    11 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is the format specifier for printing a pointer value?

1070


What is the right type to use for boolean values in c?

1085


What are reserved words with a programming language?

1199


Simplify the program segment if X = B then C ← true else C ← false

3063


In C programming, how do you insert quote characters (‘ and “) into the output screen?

1577


what are bit fields in c?

1817


write a program to convert a expression in polish notation(postfix) to inline(normal) something like make 723+* (2+3) x 7 (not sure) just check out its mainly printing expression in postfix form to infix.

2880


can anyone please tell about the nested interrupts?

2182


Do you know the difference between exit() and _exit() function in c?

1108


What is difference between structure and union in c programming?

1170


What is the difference between NULL and NUL?

1351


In a header file whether functions are declared or defined?

1171


What is malloc return c?

1077


Synonymous with pointer array a) character array b) ragged array c) multiple array d) none

1106


How is a null pointer different from a dangling pointer?

1083