How do we swap or interchange any 2 numbers without using
Temporary variable...Anybody can pls answer it.. Thanks in
Advance
Answer Posted / manju
main()
{
int a=16,b=19;
a=a+b;
b=a-b;
a=a-b;
printf("a and b are:%d\t%d",a,b);
}
Output:
a and b are:19 16
| Is This Answer Correct ? | 16 Yes | 3 No |
Post New Answer View All Answers
How will you print TATA alone from TATA POWER using string copy and concate commands in C?
What is the difference between functions abs() and fabs()?
What is %d called in c?
Explain enumerated types.
What are the restrictions of a modulus operator?
What should malloc() do? Return a null pointer or a pointer to 0 bytes?
Discuss the function of conditional operator, size of operator and comma operator with examples.
What is a list in c?
If you know then define #pragma?
How do you print an address?
the real constant in c can be expressed in which of the following forms a) fractional form only b) exponential form only c) ascii form only d) both a and b
What is structure of c program?
how can f be used for both float and double arguments in printf? Are not they different types?
Explain setjmp()?
Process by which one bit pattern in to another by bit wise operation is?