函数调用

class Program
    {
         public struct chengji
        { 

        public double tiyu;
        
             

        }

         struct Student
         {
             public string Name;
             public string Age;
             public chengji Chengji;
            
        }

        static void  Out()

    {
        Console.WriteLine("你好!");
    }
        static void Out(string name)
        {

            Console.WriteLine("你好!" + name);

        }
        static int Outa(string name)
        {

            Console.WriteLine("你好!" + name);

            return 100;
        }


        static void Main(string[] args)
        {
            Out();

            Out("再见");

            int l = Outa("你好,再见");

           

           


            Student stu = new Student();
            stu.Name = "张三";

            stu.Age = "20";
            stu.Chengji.tiyu = 88;

            Console.WriteLine("学生姓名" + stu.Name + "学生年龄" + stu.Age + "学生成绩" + stu.Chengji);


            Console.ReadLine();

  

原文地址:https://www.cnblogs.com/suncan0/p/4726067.html