定义类写main方法写输出语句Java程序开发运行与工作原理编译和运行程序public class HelloWorld { public static void main(String[] args) { System.out.println("HelloWorld"); } }