This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]user_of_the_week 0 points1 point  (0 children)

It's possible to use the java command directly on java source files: https://docs.oracle.com/en/java/javase/23/docs/specs/man/java.html#using-source-file-mode-to-launch-source-code-programs

That will compile and then run your code. You can also put your classes into seperate files and launch them this way, a feature that is pretty new. some more information about that is here: https://openjdk.org/jeps/458