how to swap two nubers by using a function with pointers?
Answer / reshma
void swap(int *a, int *b)
{
int tmp;
tmp=*a;
*a=*b;
*b=tmp;
}
or
void swap(int *a, int *b)
{
*a=*a^*b;
*b=*a^*b;
*a=*a^*b;
}
| Is This Answer Correct ? | 10 Yes | 1 No |
What is identifiers in c with examples?
What should not contain a header file?
4) Write a program that takes a 5 digit number and calculates 2 power that number and prints it. i have done maximum par but i m findind problem in the commented area. please help...
What are the main characteristics of c language describe the structure of ac program?
Not all reserved words are written in lowercase. TRUE or FALSE?
write a program in c language to print your bio-data on the screen by using functions.
6 Answers College School Exams Tests, IBM,
Why is c called c?
What is pass by reference in c?
Can two or more operators such as and be combined in a single line of program code?
What is function definition in c?
How do we open a binary file in Read/Write mode in C?
wite a programme in c to linear search a data using flag and without using flags?