安装visual studio2017
新建项目


编写代码
在main方法内添加两条语句
// 向控制台写入hello world并换行
Console.WriteLine("Hello world.");
// 等待读入一个键盘操作,防止程序一闪而过
Console.ReadKey();

运行

等待片刻会弹出一个窗口,注意左下角提示
结果

参考文档:http://www.runoob.com/csharp/csharp-program-structure.html
在main方法内添加两条语句
// 向控制台写入hello world并换行
Console.WriteLine("Hello world.");
// 等待读入一个键盘操作,防止程序一闪而过
Console.ReadKey();
等待片刻会弹出一个窗口,注意左下角提示
参考文档:http://www.runoob.com/csharp/csharp-program-structure.html
本文标题:C#魔灵-lesson_01-Helloworld
本文链接:https://www.haomeiwen.com/subject/jdzrfqtx.html
网友评论