I landed in the Java universe again, after evolving through a few JavaScript frameworks and a bit of C++ and a ton of Python. I had given up on Java sometime in the past and I don't really know why.

The Basics

The Java Buzzwords

  • Simple
  • Secure
  • Portable
  • Object-oriented
  • Robust
  • Multithreaded
  • Architecture-neutral
  • Interpreted
  • High performance
  • Distributed
  • Dynamic

Setting up the Environment

Installing Java

I used the Java SE Development Kit (JDK) 8 (developer version 1.8) by OracleOpenJDK is the same sans proprietary issues. Once past that, I set the environment variables JAVA_HOME and PATH to point to the directories where the binaries of the Java toolchain reside.

Code Editor v/s IDE

Personal Preference. VS Code as an editor and IntelliJ IDEA as an IDE are great choices. I use both


Executing java -version && javac -version outputs whatever is given below:

$ java -version && javac -version
java version "1.8.0_231"
Java(TM) SE Runtime Environment (build 1.8.0_231-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.231-b11, mixed mode)
javac 1.8.0_231

Bytecode Stuff


Here's a flowchart!

The  Flowchart


I wrote text file with a .java extension containing some lines of code and compilde it to Java Bytecode with the javac compiler. Compilation resulted in a binary .class file that will be used for interpretation.


The .class file is loaded to the Java Virtual Machine using a Class Loader in the JVM. The .class files are vulnerable and using a hex editor, an attacker can change the behaviour of a program. To overcome this issue, the bytecode is then verified using the Bytecode Verifier in the JVM. The Java Just-In-Time (JIT) Compiler or Runtime Interpreter then interprets the bytecode and produces machine code depending on the system architecture which can then be loaded into memory for execution.

The Code

Here's how a "Hello, World!" would look like in Java. Classes, I know, yes, there is some overhead involved but walk along. And yes, it is a little verbose.

public class HelloWorld {
    public static void main(String[] args) {
        System.out.println("Hello, World!");

But I should add comments! So the final source code could be something like:

// HelloWorld.java

 * Hello World Application
 * @author sudipto@ghosh.pro

public class HelloWorld {
    public static void main(String[] args) {
        System.out.println("Hello, World!");

To compile my HelloWorld.java file to bytecode, I ran the javac compiler with a CLI argument.

$ javac HelloWorld.java 

This created a HelloWorld.class file in the same directory. Opening it in a text editor was not of much use as it is a binary file but you can surely see a few symbols here and there.

Using the Java Class File Disassembler, we can see some interpreted assembly code. To view that, I used the javap tool in the JDK. Running javap -c HelloWorld outputted some code which also points to the fact that if there is no default constructor, the compiler puts it there!

To load my HelloWorld.class into the JVM and execute it, I invoked java with a command-line argument that matches the base name of the .class file.

$ java HelloWorld

Once this command was executed, the message Hello, World! correctly printed onto the screen, technically console.

Learning Resources

I referred to Java: The Complete Reference (9th ed.) by Herbert Schildt and the Oracle documentation for getting around the intricacies of the language.

Project 01: Text Editor

A basic text editor that can open and save text files. It also features a word counter and character counter. Learnt about StringTokenizerFileReaderFileWriterBufferredReaderBufferredWriter and StringBuilder. The GUI was designed with Swing and the IntelliJ IDEA GUI Designer.




Project 02: Store Management System

Used the SQLite JDBC Driver to interface with a database and manage customers, inventory items and process orders of a dummy store. The GUI was designed with Swing and the IntelliJ IDEA GUI Designer. Had to struggle a bit with JTable but figured it out at last.




Guest Blogger

botanical profile

Special thanks to our guest blogger Sudipto Ghosh for his contribution to the Ronald James Blog this week.

Visit the original link for this blog here.

twitter dev 

Who Are Ronald James

We are a leading niche digital & tech recruitment specialist for the North East of England. We Specialise in the acquisition of high-performing technology talent across a variety of IT sectors including Digital & Technology Software Development.

Our ultimate goal is to make a positive impact on every client and candidate we serve - from the initial call and introduction, right up to the final delivery, we want our clients and candidates to feel they have had a beneficial and productive experience.

Contact our Team

If you’re looking to start your journey in sourcing talent or find your dream job, you’ll need a passionate, motivated team of experts to guide you. Check out our Jobs page for open vacancies. If interested, contact us or call 0191 620 0123 for a quick chat with our team.

Let's be Friends!

Follow us on our blog, FacebookLinkedInTwitter or Instagram to follow industry news, events, success stories and new blogs releases.


Back to Blog

</Follow Us>