Mac terminal Javac
Open the Terminal‘s vim , then write them:
public class test{
public static void main(String[] args){
System.out.println("test");
}
}
First, to make the .class file, this is java‘s object file.
? Desktop javac test.java
Then run this java app.
? Desktop java test test.class
test
时间: 2024-07-30 22:44:06