Swap Two Numbers Without using Temporary Variable in C#

namespace Swap
{
Class Test
{
public static void Main(string[] args)
{
int a,b;
a=1;
b=2;

a=a+b;
b=a-b;
a=a-b;
Console.Writeline(a.Tostring());
Console.Writeline(b.Tostring());
Console.ReadLine();
}
}
}

Comments

Popular posts from this blog

Types of Architects

Basic measurements

Search html table contents based on its td using Jquery