I bought Java All in one for Dummies to begin learning more about java ISBN: 978-0-470-37172-5
Stuff packed in my brain on 8/4/13
Previously I have installed everything I have used in the past while dabbling in JAVA. I still have 0% experience.
I already have Java Runtime Environment installed on my computer as well as a Java Development Kit and Netbeans
(I used for a few beginner tutorials earlier this year)
Tutorial #1 - Test the Java Compiler
The dummy book began with the Hello World! java example.
Before The tutorial began the book asked me to set the path in system properties > advanced > Environment variable
> PATH > click edit > semicolon after what is already in box > copy and paste the java bin directory then
The Program to test the compiler
The Dummies book was not a step by step in this process and so I had to google what a cd was in a command prompt
This video was great. It directed how to use the CD - Change directory, change class, and how to test run the Java Compiler (Javac in the prompt)
cd\ > dir > cd\test (A folder I saved in C:\ that holds my test java files) > javac HelloApp.java (converts to class file) > java apples > (OUTPUT) Hello Youtube!
Here is the code used on the video
class apples{
public static void main(String args[])
{
System.out.println("Hello youtube!");
}
}
and a picture of my output
Java for Dummies or JFD also noted that javaac *.java can compile all the files in a folder
Feels good to take my first step into Java. Any tips would be appreciated, thanks!


No comments:
Post a Comment