swapping the three values in c++


Image result for c++ logo


#include<iostream>
#include<conio.h>
using namespace std;
int main()
{
int a,b,c;
cout<<"enter the value of a \n";
cin>>a;
cout<<"enter the value of b \n";
cin>>b;
cout<<"before swapping value are "<<a<<"\n"<<b<<endl;
c=a;
a=b;
b=c;
cout<<"after swapping value are "<<a<<"\n"<<b<<endl;
return 0;
getch();
}