what is the algorithm used to swap two numbers
Answers
Answered by
0
create 3 integer variables with one being temporary.
Let the variables be
int x,y, temporary;
assign a value to x and y and give temp a redundant value.
temporary = x;
x = y;
y = temporary;
Similar questions