How to write the code of the program to swap two numbers
with in one statement?
Answer Posted / rajitha
#include<stdio.h>
main()
{
int a=3,b=4;
b=a+b-(a=b);
printf("%d",a);
printf("%d",b);
}
| Is This Answer Correct ? | 19 Yes | 4 No |
Post New Answer View All Answers
What is #include called?
Why pointers are used?
How would you use the functions fseek(), freed(), fwrite() and ftell()?
When a c file is executed there are many files that are automatically opened what are they files?
stripos — Find position of first occurrence of a case- insensitive string int stripos ( char* haystack, char* needle, int offset ) Returns the numeric position of the first occurrence of needle in the haystack string. Note that the needle may be a string of one or more characters. If needle is not found, stripos() will return -1. The function should not make use of any C library function calls.
while loop contains parts a) initialisation, evalution of an expression,increment /decrement b) initialisation, increment/decrement c) condition evalution d) none of the above
Is c object oriented?
Explain how can I read and write comma-delimited text?
What is the difference between array and structure in c?
Are negative numbers true in c?
What is a static function in c?
What extern c means?
What is a program?
Is linux written in c?
Explain what is the difference between far and near ?