Computer Science, asked by tomba4017, 1 year ago

Write a program in c++ to swap two numbers by reference method

Answers

Answered by surajithere
4
#Include<iostream>
using namespace std;

int main()
{
int first, second, temporary=0;
cout<<"Enter the two numbers to swap: ";
cin>>first>>second;
temp=first;
first=second;
second=temp;
cout<<"Your result aftr swapping is "<<first<<" "<<second;
return 0;
}

surajithere: Why don't you mark it as Brainliest?
Similar questions