write a program to swap Two numbers without using temp variable.

Answer Posted / nagakishorebabu

a=a+b;
b=a-b;
a=a-b;
printf("a %dand b %dis :",a,b);

Is This Answer Correct ?    181 Yes 43 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the use of keyword 'register' with respect to variables.

562


show how link list can be used to repersent the following polynomial i) 5x+2

1647


Is there sort function in c?

556


how could explain about job profile

1431


Why do we use int main?

576






Can true be a variable name in c?

533


What is volatile, register definition in C

657


What are the usage of pointer in c?

678


Explain what is page thrashing?

584


Write a program to check whether a number is prime or not using c?

548


What are directives in c?

525


Are there namespaces in c?

544


What is the difference between exit() and _exit() function?

578


How can I pad a string to a known length?

591


What are variables and it what way is it different from constants?

748