【C#学习笔记】函数调用

using System;

namespace ConsoleApplication
{
    class Program
    {
        static int Add(int a, int b)
        {
            return a + b;
        }

        static void Main(string[] args)
        {
            int a = 1,b = 2;
            int c = Add(a, b);
            Console.Write(c);
            Console.Read();
        }      
    }
}

 

转载于:https://www.cnblogs.com/tiandsp/p/7440405.html

你可能感兴趣的:(【C#学习笔记】函数调用)