namespace 函数参数默认值
{
    class Program
    {   
        public static void Test(int i =100)
        {
            Console.WriteLine("{0}",i);
        }
        static void Main(string[] args)
        {
            Test();
            Test(222);
            Console.Read();
        }
    }
}

输出:100

   222

相关文章: