using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace mytest
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Hello World!");
Console.ReadLine();
}
}
}
C#的第一个HelloWorld程序
认识C#程序结构
一个C#程序主要包含以下几个组成部分
1.命名空间声明(Namespace Declaration)
2.一个Class
3.可选的Class方法
4.可选的Class属性
5.一个Main()方法
6.语句(Statements)和表达式(Expressions)