FAQ: Hello World: Java - Compilation: Creating Executables

You have to hit the Check Work (green) button after each step…it’s kinda annoying, but it’s a good fail-safe for beginners.

I’m totally new at this, but it looks to me like your program is executing just fine, it’s just missing statements in the Compiling.java file.

what exactly am i doing wrong here?

this lesson has turned me off Java on code academy, very poor lesson, poorly laid out poorly explained, even on reveal its not clear what the solution is. Im out

Hey @newcoder73, welcome to the forums!

Ugh, that’s always super annoying when you come across an exercise like that. Are you sure you want to leave Codecademy though? No website or coding program is perfect and I would recommend re-reading the lesson and trying to understand it better. If you still have trouble with it, you can go ahead and submit a bug report so the people at Codecademy can see that people are having trouble with this and try to fix it.

How do you compile because idk.

javac Compiling.java
On running this multiple times , why doesn’t the compiler create multiple .class files ? Are they replaced with the latest one?

You need to tipe “java Compiling” and after you did that just tipe “ls”

is ‘����4#

aJava is a class-based language.a !""Java classes have a ‘main’ method.%Java statements end with a semicolon.Programming is… fun! Compilingjava/lang/Objectjava/lang/SystemoutLjava/io/PrintStream;java/io/PrintStreamaprintln(Ljava/lang/String;)V!

’ supposed to show up while running the class file for compiling?
need help because It caused it to be impossible to complete

I believed I typed the command javac correctly, however the site does not accept it. What is wrong?


You need to press Check Work in order to run the code!

Hey, I know I might be late with the answer but this had me thinking too. I dont know if this is a bug or something else but the answer is the below. ( I found it weird…)

javac Welcome.java.java

I was having difficulties with this program but now I got it to work! You just have to follow the instructions. Just type in (ls) the shorter way for list and then use [ java ] at the beginning of “Compiling” so the code can execute that java file.

I have no clue how to finish this
The whole thing was really hard to understand. It wasn’t the code it was the ways to finish the tasks

Remember that you need to include the file extension when compiling (so you would use javac Compiling.java and not javac Compiling). We omit the file extension when we actually execute the program, where we would use java Compiling. Make sure you compile a program before executing it.

Welcome to the forums!