write a program to swap Two numbers without using temp variable.
Answer Posted / joshin
main()
{
printf("enter two number");
scanf("%d%d",&a,&b);
printf("swaped result is b=%d\na=%d",b,a);
}
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What are the main characteristics of c language describe the structure of ac program?
Given only putchar (no sprintf, itoa, etc.) write a routine putlong that prints out an unsigned long in decimal. [ I gave the obvious solution of taking % 10 and / 10, which gives us the decimal value in reverse order. This requires an array since we need to print it out in the correct order. The interviewer wasn't too pleased and asked me to give a solution which didn't need the array ].
Can a void pointer point to a function?
Why dont c comments nest?
Where is c used?
How do I round numbers?
Write a program to compute the similarity between two strings - The program should get the two strings as input - Then it will output one single number which is the percentage of similarity between the two strings
What are the standard predefined macros?
What is pointer in c?
If null and 0 are equivalent as null pointer constants, which should I use?
Why we write conio h in c?
What's a good way to check for "close enough" floating-point equality?
What is the function of this pointer?
What is huge pointer in c?
Is it fine to write void main () or main () in c?