Skip to content
Sign upLog in
This post is read-only. Explore Repls and connect with other creators on Community.View Community
The info in this post might be out of date, check out our docs instead. View docs
4

Changing the main class name in Java -- is it possible?

LisaKossiver
LisaKossiver

In Java there is no way to change the class name or the java file away from Main, and give it a meaningful name?

2 years ago
You are viewing a single comment. View All
2
DynamicSquid
DynamicSquid

In the console, type rm Main.java, then hit the "new file" button, and rename the file whatever you like. Then create a new file called .replit, and type this:

run="javac filename.java; java filename"

I don't do java, so that may be wrong

2 years ago