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...

How do we swap or interchange any 2 numbers without using
Temporary variable...Anybody can pls answer it.. Thanks in
Advance

Answer Posted / girish

#include<stdio.h>
#include<conio.h>
#include<stdlib.h>
void main()
{
int a,b;
clrscr();
printf("Enter the two values:");
scanf("%d%d",&a,&b);
swap(a,b);
pritnf("the swaping of given two values are:\na=%d,b=%
d",a,b);
getch();
}

Is This Answer Correct ?    0 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Compare interpreters and compilers.

1039


An instruction which is analysed and acted upon by the processor prior to the compiler going its work a) directive b) constructive c) constant d) absolute mode

1047


What is the difference between the expression “++a” and “a++”?

1188


Write a program to check armstrong number in c?

1102


What is nested structure with example?

1036


How can you invoke another program from within a C program?

1036


Distinguish between actual and formal arguments.

1024


What is integer constants?

1030


How can I recover the file name given an open stream or file descriptor?

1046


Why are some ANSI/ISO Standard library routines showing up as undefined, even though I've got an ANSI compiler?

1092


Given a valid 24 hour format time find the combination of the value and write a program ,do not hard the value and if any other inputs provided should work with the logic implemented Input: 11:30 Output: 13:10 Input: 18:25 Output: 21:58

1486


What are disadvantages of C language.

1121


Why doesnt this code work?

1020


What are derived data types in c?

1029


Explain the use of bit fieild.

1104