static void Main(string[] args) { object a = new object(); object cst=a; a = 6; Console.WriteLine(a + " " + cst); a="klm"; Console.WriteLine(a+" "+cst); }
output:
6 System.Object
klm System.Object
I expected the result as:
6 6
klm klm
Any explanation?