blog posts

Learn JDK, JRE and JVM in Java and their differences

Learn JDK, JRE and JVM in Java and their differences, In this article you will learn the basic differences between JDK, JRE and JVM.

What is JVM?

JDK, JRE and JVM (Java Virtual Machine) is an abstract machine that enables the system to run a Java program.

When you run a Java program, the Java compiler first compiles the Java code into a bytecode. The JVM then converts the bytecode to local machine code (a set of instructions that the computer’s CPU executes directly).

Java is a platform-independent language. Because when you write Java code, it’s actually written for the JVM, not your physical device (computer). Because JVM runs operating system-independent Java bytecode, Java is platform-independent.


What is a JRE?

(Java Runtime Environment) is a software package that provides Java class libraries with Java Virtual Machine (JVM) and other components to run Java applications. The JRE includes the JVM.

C: \ Users \ Mr \ Desktop \ java-realtime-enviornment_0.jpg

If you want to run Java applications without expansion, you need JRE. You can download the JRE from the Java 8 Runtime Environment 8 page.

What is JDK?

JDK (Java Development Kit) is a software development kit for developing applications in Java. When you download the JDK, the JRE is also downloaded and there is no need to download it separately. In addition to the JRE, JDK also includes a number of development tools (compilers, JavaDoc, Java Debugger, etc.).

C: \ Users \ Mr \ Desktop \ java-development-kit.jpg

If you want to develop Java applications, download JDK.

The image below shows the relationship between JVM, JRE and JDK.

Attributes of Java

java attributes

1. Java is an independent platform

We all know that java, an independent platform and due to this characteristic, acquired by many.

As a result, if we code anything on this platform, Java, it will successfully run on other platforms as well.

2. Variety of methods

Another reason why Java, used globally- it has a huge standard library.

It has hundreds of methods which allows the developers to code in any software of any package.

3. It is an object-oriented language

Programming can be done in a variety of styles, but the most popular style is the object-oriented programming style.

The object-oriented programming- most popular style

Because of its characteristic of cutting down a complex problem into smaller sets.

4. Java is swift

Earlier, java, being criticized for being slower, compared to other platforms but now, characteristic of being quick has taken away the hearts of many.

Nowadays, Java, being compared with other programming languages like Python and PHP.

5. Java is a sturdy platform

Security, being the first priority makes java a better platform to work on.

For running the applications, best platform to work on.

Privacy of data maintained

It can automatically manage memory.

Significance of java

  • Java- a platform independent language through the help of Bytecode.
  • Portable language; JVM gets automatically install.
  • It is an independent language, whereas, JVM is a dependent language.