it should be:Console.WriteLine("hello world");

解决方案 »

  1.   

    WriteLine("hello world");//错了
    如下:
    Console.WriteLine("hello world");
      

  2.   

    你编的程序是应用台程序,Console.WriteLine("hello world");
    WriteLine 前面必须加Console。
      

  3.   

    楼上的几位说得对,应该是:
      Console.WriteLine("hello word");
    这里,Console 是名称空间 System 中的类,而 WriteLine() 是 Console 类中的方法。如果只写 WriteLine(...),则认为 WriteLine(...) 是当前类,即 Class1 类中的方法,自然会出错。
      你是从哪本书中看学的例子? 那本书肯定有问题。