自学java第一天(写第一个程序)

1.定义calss 类

  class{

  }

2.添加主(main)方法/函数

 public static void main(String[] args){

}

3.添加输出语句

System.out.println("hello world")

4.如下:

calss java1{

  

 public static void main(String[] args){

  System.out.println("hello world")

}

}

猜你喜欢

转载自www.cnblogs.com/2500486123llp/p/11621196.html