Introduction

Java is a general-purpose programming language designed by James Gosling (Calgary 1956 – ) in 1994. At that time, James Gosling was employed by Sun Microsystems. In 2010 Oracle Corporation acquired Sun Microsystems and Gosling left the company to join Google. James Gosling designed the Java language to simplify the programming of smart (household) appliances like smart televisions, microwave ovens, clothes dryers, dishwashers, washing machines, air conditioners, etc.
Portability
Traditional languages
Appliances make use of many different processors. Each processor has its own low-level machine language. It is very difficult and time-consuming to write programs directly into machine language. Therefore, developers will write programs in a high-level language (like Cobol, Fortran, Pascal, C…) and use compilers to translate the original instructions (the source code) into machine language. For each high-level programming language and for each combination of hardware and operating system, separate compilers have to be developed.

Java
One of the main design goals of the Java programming language was portability: a program must run similarly on any computer system without the need to recompile the source code into machine language.
To achieve this objective of portability, Java uses a two-step approach:
- In a first step, the Java source code (.java extension) will be compiled into an intermediate machine language (Java bytecode) defined for a hypothetical computer (Java Virtual Machine (JVM)). This Java bytecode has a .class extension.
- In a second step, an interpreter (part of the Java Virtual Machine) converts the Java bytecode into machine code and executes it. This translation process is also called just-in-time (JIT) compilation.
