码迷,mamicode.com
首页 > 其他好文 > 详细

函数调用

时间:2015-08-13 08:53:28      阅读:110      评论:0      收藏:0      [点我收藏+]

标签:

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();

  

函数调用

标签:

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

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!