Ask coding questions

← Back to all posts
Compiling
JohnnyHo1 (0)

I am trying to get this code ran correctly but it keeps on telling me an error? I have saved the file as MyFirstProgram.java and this is program is from the book Absolute Java 6th edition by Walter Savitch; pg. 6 Display 1.1.

Thank you

Commentshotnewtop
Masy (21)

rename Main.java to the class name

JohnnyHo1 (0)

@Masy Ok, where do I go to rename the file? I created a new file and copied and paste it and says error 2, duplicate?

Masy (21)

@JohnnyHo1 what kind of computer/laptop are you on?

JohnnyHo1 (0)

@Masy Dell, so window 10. I also have the program Geany installed but cant seem to get it to work properly.. I am sorry I am totally new to the coding programming.

Masy (21)

@JohnnyHo1 use eclipse, you will have much better results with java

JohnnyHo1 (0)

@Masy I have to use Geany since the professor uses Geany in her class. Is there a video or site to gasp a better concept on the use of compiling and executing Java?? Thank you

Masy (21)

@JohnnyHo1 No problem, let me know if you need anymore help