#include <iostream>
using namespace std;
main()
{
int a,b;
cout<<"Enter 2 Numbers"<<endl;
cin>>a>>b;
cout<<"Before Swapping :\nThe first Number = "<<a<<endl;;
cout<<"The Second Number = "<<b<<endl;
a=a+b;
b=a-b;
a=a-b;
cout<<"After Swapping :"<<endl;
cout<<"The first Number = "<<a<<endl;
cout<<"The second Number = "<<b<<endl;
}
No comments:
Post a Comment