jre (Java Runtime Environment) is an environment that loads
.class files and executes bytecode.
If we fully describe what
JRE is, then this is the implementation of
Java virtual machine.
Java virtual machine contains and performs:
• Classloader to load .class files in which bytecode
• compiler JIT (just-in-time) for dynamic compilation of bytecode at runtime
• thread control
• garbage collector for automatic memory management. At Java, we don't write code to remove an object from memory, that's done by the garbage collector. The garbage collector deletes an object when it is not needed.