#include <iostream>
using namespace std;
int main()
{
cout<<"\n Swapping Program";
int x,y,temp;
cout<<" \n Enter a Value Of X : ";
cin>> x;
cout<< x;
cout<<" \n Enter a Value Of Y : ";
cin>> y;
cout<< y;
cout<<"\n\n Before Swapping :\n";
cout<<"\n Value Of X = " << x <<"\n Value Of Y = " << y ;
temp=x;
x=y;
y=temp;
cout<<"\n\n After Swapping :\n";
cout<<"\n Value Of X = " << x <<"\n Value Of Y = " << y ;
return 0;
}
To embed this project on your website, copy the following code and paste it into your website's HTML: