using System;class ProgramWithTypeInferenceAndAnonymousType{ public static void Main() { var emp = new {Id="1", Name="Amit",Address="#123"}; Console.WriteLine("Id is " + emp.Id); Console.WriteLine("Name is " + emp.Name); Console.WriteLine("Address is " + emp.Address); }}OUTPUT
No comments: