Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Write a program that takes three variables(a,b,c) in as
separate parameters and rotates the values stored so that
value a goes to b,b,to c and c to a

Answer Posted / nitin

void main()
{
int a,b,c;
printf("enter the values of a,b &c");
scanf("%d%d%d",&a,&b,&c);
c=c+a;
a=c-a;
c=c+b;
b=c-b;
c=c-b;
printf("\n values of ab & c are=%d%d%d",a,b,c);
getch();
}

Is This Answer Correct ?    5 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are pointers? What are different types of pointers?

1053


Can we declare variable anywhere in c?

918


What is the difference between malloc calloc and realloc in c?

1065


What is the main difference between calloc () and malloc ()?

1092


program to find out date after adding 31 days to a date in the month of febraury also consider the leap year

3014


What is calloc malloc realloc in c?

1008


please explain clearly about execution of c program in detail,in which stage are the printf sacnf getting into exeecutable code

2129


What does nil mean in c?

1176


What is the purpose of scanf() and printf() functions?

1170


What is s or c?

1006


Which is best book for data structures in c?

1038


how can i write a program that prints out a box such that whenever i press any key8(coordinate number) on the keyboard, the box moves.

1622


Write a programme using structure that create a record of students. The user allow to add a record and delete a record and also show the records in ascending order.

2036


how to write optimum code to divide a 50 digit number with a 25 digit number??

3202


What is malloc return c?

972