void swap(int a,int b)
{
a=a+b;
b=a-b;
a=a-b;
}

in this code always gives the same result for all case

Answer Posted / sunny

NO
Means we can give diff values give different answer.
like
we can give a=80,b=100
a=180,b=20,a=20

Is This Answer Correct ?    3 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is it cc or c in a letter?

568


What does c mean?

589


Do you have any idea about the use of "auto" keyword?

666


Why c is called top down?

629


What does void main () mean?

736






What are the types of type specifiers?

623


When should I declare a function?

623


How many data structures are there in c?

619


about c language

1607


What is the difference between printf and scanf in c?

752


int i[2], j; int *pi;i[0] = 1; i[1] = 5; pi = i; j = *pi + 1 + *(pi + 1)Value of j after execution of the above statements will be a) 7 b) 6 c) 4 d) pointer

657


can any one tel me wt is the question pattern for NIC exam

1559


what is the significance of static storage class specifier?

1666


How do you print an address?

749


Does c have enums?

603