Description :
- Exchange values of two objects
Example
//Declare two example objects (same type)
int a = 60, b = 50;
//a:60 and b:50
std::cout<<"Before: "<<"a = "<<a<<" and b = "<<b<<"\n";
std::swap(a,b);
//a:50 and b:60, after swap
std::cout<<"After: "<<"a = "<<a<<" and b = "<<b;