copy swap c++ code example
Example: c++ swap function
int main()
{
int a = 5;
int b = 10;
swap(a, b);
cout << "a = " << a << endl;
cout << "b = " << b << endl;
}
int main()
{
int a = 5;
int b = 10;
swap(a, b);
cout << "a = " << a << endl;
cout << "b = " << b << endl;
}