plz answer....A program that takes 3 variables e.g a,b,c in
as seperate parameters and rotates the values stored so
that value goes a to b, b to c and c to a .
Answer Posted / ruchi
#include<stdio.h>
#include<conio.h>
int main()
{
int a,b,c,d;
printf("\nEnter the three numbers ");
scanf("%d %d %d",&a,&b,&c);
a=a+b;
b=a-b;
d=c;
c=a-b;
a=d;
printf("\nNow the values are ");
printf("%d %d %d",a,b,c);
getch();
}
| Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
write a program which the o/p should b in such a way that s triangle if I/p is 3,a Square/rectangle if I/P=4,a pentagon if I/P=5 and so on...forget about the I/P which is less than 3
What is return in c programming?
Differentiate between the expression “++a” and “a++”?
write a program to print data of 5 five students with structures?
List the difference between a While & Do While loops?
How can I sort a linked list?
Can 'this' pointer by used in the constructor?
What is a dynamic array in c?
Find duplicates in a file containing 6 digit number (like uid) in O (n) time.
What is action and transformation in spark?
How to declare a variable?
Does c have function or method?
typedef struct{ char *; nodeptr next; } * nodeptr ; What does nodeptr stand for?
What are different storage class specifiers in c?
What is the use of static variable in c?