using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections;namespace chat3
{
class Program
{
public static void main()
{
IDictionary environment = Environment.GetEnvironmentVariables();
Console.WriteLine("环境变量名\t=\t环境变量值");
foreach (string environmentKey in environment.Keys )
{
Console.WriteLine("{0}\t=\t{1}",environmentKey,environment[environmentKey].ToString());
}
}
}
}
为什么提示错误 不包含适合于入口点的静态“main”方法 为什么会这样,编写代码的时候没有提示错误,调试的时候出现这样的错误,我该怎么办?
没人告诉你C#是区分大小写的吗?
C#中没有main()这么个函数,要写成Main()是规定的,必须这么写