#include<iostream>
using namespace std;
#include<conio.h>
int main()
{
int a,b;
cout<<"Enter two number:\t";
cin>>a>>b;
cout<<"\nBefore swapping:\t";
cout<<a<<"\t"<<b;
a=a+b;
b=a-b;
a=a-b;
cout<<"\nAfter swapping:\t";
cout<<"\t"<<a<<"\t"<<b;
getch();
}
0 comments:
Post a Comment