static void Main(string[] args) { Program1 obj = new Program1(); obj.Test1(); obj.Test2(); Console.ReadKey(); }
static void Main(string[] args) { Program1 p = new Program1(); p.Test1(); p.Test2(); p.Test3(); var i = 20; long result = i.Factorial(); String str = "Nitesh kumar.kushwaha"; int compareValue; System.DateTime theDay = new System.DateTime(System.DateTime.Today.Year, 5, 21); compareValue = theDay.CompareTo(DateTime.Today); str = str.ToProper(); Console.WriteLine(str); Console.WriteLine("Factorial of {0} is : {1}", i, result); Console.ReadKey(); }
public static void Test2(this Program1 p) { Console.WriteLine("Test 2 EXT method call"); }