前言:公司开始转型java,作为javaer,负责其他同事转型,期间以为工作需要,需要简单学习c#语法,顾有此文,及其后续的一系列文章(c#里头的一些优点,可以为提升java的思想带来帮助)

1. 安装Visual Studio(略,自己是一直next,安装的版本是2012)

2.创建第一个hello world程序

c#之hello world

3.配置环境变量

c#之hello world

 

加入:C:\Windows\Microsoft.NET\Framework\v4.0.30319;

c#之hello world

运行

c#之hello world

 如果想直接在visual Studio中运行命令窗体,而不是一闪而过

可以再最后加上 Console.ReadKey();

namespace helloworld
{
    class Program
    {
        static void Main(string[] args)
        {
            Console.WriteLine("hello world");
            Console.ReadKey();
        }
    }
}

参考:http://msdn.microsoft.com/zh-cn/library/k1sx6ed2.aspx

 

相关文章:

  • 2022-03-01
  • 2021-06-03
  • 2021-10-31
  • 2021-09-28
  • 2021-12-12
  • 2022-01-26
  • 2021-12-19
  • 2021-12-11
猜你喜欢
  • 2021-08-31
  • 2022-02-14
  • 2021-12-22
  • 2021-08-11
  • 2022-12-23
  • 2021-06-30
  • 2021-09-08
相关资源
相似解决方案