Setting up Java
In this post we will see how to set up Java Development Kit(JDK) and get started with JAVA programming.
What is JDK after all?
JDK is java development kit.Sounds fancy? Basically JDK is nothing but set of libraries which can be used at compile and runtime when you start coding in java.Think of it as an environment needed to compile, debug and run you java programs.
To describe it in one statement - The Java Development Kit (JDK) is a software development environment used for developing Java applications and applets. It includes the Java Runtime Environment (JRE), an interpreter/loader (java), a compiler (javac), an archiver (jar), a documentation generator (javadoc) and other tools needed in Java development.
Before we proceed to downloading JDK it is important to know its types and purpose. We have JSE(java Standard Edition) and JEE(Java Enterprise Edition).As long as you don't use any application servers or other advanced distributed architectures you will be perfectly fine with former one.
You can get Java JDK here. You can also check the difference between JSE and JEE in the previously mentioned link.After you download the JDK just unzip it and install.You may need to change enviroment variables if you are compiling and running programs from command line.
Where do i actually write my code?
You can write your code in any standard text editor notepad/notepad++ for Windows or vi/emacs for Linux.
For beginners its is recommended to write and compile on command line to get familiar with how things work but all you want is to write Java programs you can directly use IDE(Integrated Development Environment).There are two IDE's that are commonly used-