Write a program to exchange two variaables without temp
Answer Posted / srinivas
main()
{
int a=3,b=2;
a = (a+b)-(b=a);
printf("a=%d,b=%d",a,b);
}
o/p:- a=2,b=3
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What do you understand by friend-functions? How are they used?
What is wrong with this declaration?
Give differences between - new and malloc() , delete and free() ?
Write a program to swap two numbers without using third variable in c?
What is wild pointer in c?
What does %d do in c?
Why is python slower than c?
Describe dynamic data structure in c programming language?
write a program to generate address labels using structures?
What is echo in c programming?
Can you please explain the difference between syntax vs logical error?
What is the code in while loop that returns the output of given code?
If i have an array 0 to 99 i.e,(Size 100) I place the values 1 to 100 randomly like a[0]=29,a[1]=56 upto array[99].. the values are only between 1 to 100. getting the array values by using scanf.. If i entered one wrong element value line a[56]=108. how can i find it.. and also how to find the missing value in 1 to 100.. and i want to replace the missing values.. any one of them know please post your answer..
What is the significance of scope resolution operator?
please send me the code for multiplying sparse matrix using c