1.1 第一个Java程序-输出hello world

2019-02-02  本文已影响1人  harukou_ou

打开hello.java,看到:

package newtest;

public class Newhello {

    public static void main(String[] args) {
        // TODO Auto-generated method stub

    }

}

在注释下方填写代码(编写代码时可按下Alt+/进行关键字的补全):

package newtest;

public class Newhello {

    public static void main(String[] args) {
        // TODO Auto-generated method stub
        System.out.println("hello world!");
    }

}

点击运行,在下方console中观察结果。

上一篇 下一篇

猜你喜欢

热点阅读