编写一个C#控制台应用程序,在其中输出程序接受的参数个数。

日期:2017-11-25 14:07:32 人气:2

编写一个C#控制台应用程序,在其中输出程序接受的参数个数。

c# 的程序的执行入口是 [STAThread] static void Main(string[] Args) 其中 (string[] Args) 就是你在控制台出入的参数,通过判断 Args 的数量就可以输出你要求的信息 示例 [STAThread] static void Main(string[] Args) { int iL = Args.Length;
    A+
热门评论