示例#1
0
        static void Main(string[] args)
        {
            MethodInfo[] ms = typeof(object).GetMethods();
            foreach (MethodInfo m in ms)
            {
                Console.WriteLine(m.ToString());
            }
            Console.WriteLine(FiboCalculator.Equals(10, 0.0));
            Console.WriteLine("***Fun With Conversions ***");
            int myInt = 12345678;
            myInt.DisplayDefiningAssembly();
            System.Data.DataTable dt = new System.Data.DataTable();
            dt.DisplayDefiningAssembly();

           Console.WriteLine( myInt.ReverseDigits());
           Console.WriteLine("扩展接口测试");
           string[] data = { "Wow", "this", "is ", "sort", "of", "annoying", "but", "in", "a", "weird", "way", "fun" };
           data.PrintDataAndBeep();
                Rectangle r=new Rectangle(5,4);
            Console.WriteLine(r.ToString());
            r.Draw();
            Square s = (Square)r;
            Console.WriteLine(s.ToString());
            s.Draw();
            Console.WriteLine(GC.GetTotalMemory(false)+"---"+GC.MaxGeneration);
          //  Console.ReadLine();
            BuildAnonType("BWM", "red", 1234);
        }