You Must Know This About Java - I
Tags: java, beginners, discuss, codenewbie
Published: 2021-05-31 13:05:28

Hello All👋 I hope you all are doing well. This is my 3rd Java article, in this article I have compiled together different basic concepts in a logical order, these are the topics that you must know about Java, it doesn't matter you choose it as your career path or not you must have idea about it. I don't want to make this a very long so I have decided to make it into parts.
# Let's begin...
## History
Arguments for modernization don’t always translate into “out with the old and in with the new.” You might have heard about many technologies those were in trend but no idea with time where they have gone, on the other hand Java is there from more than 2 decades as it stayed strong. James Gosling in year 1995 introduced Java. The project was initiated in 1991 and the team worked on it was called green team and first named it as **Greentalk** with file extension .gt after that it was named **Oak** (Oak is symbol of strength) and later on in the year 1995 it was renamed as **Java**(Java is island in Indonesia where the first coffee was produced) due to some trademark issues. Okay let's not get more involved in history.
>### Principles for creating Java
![princi1.jpg](https://cdn.hashnode.com/res/hashnode/image/upload/v1622452212456/GAW68i1Uw.jpeg)
I have discussed some of these in my articles earlier and will be discussing more in future articles.

## What is Java?
Java is a programming language and a platform. A Java platform is a particular environment in which Java programming language applications run, to learn more about it you can check my last article ***[Java Platforms](https://dev.to/ritvikdubey27/java-categories-platforms-editions-32ba)***. Java is a an Object Oriented Programming language, it is a topic of debate that whether Java is a purely Object Oriented Programming language or not, since Java supports most of the Object Oriented Programming principles still on the other hand it does not support a few features like Multiple Inheritance(supports with implementing interface), Operator Overloading etc. There is a strong argument of primitive datatypes, so in java we have **Wrapper Classes** corresponding to datatypes, I'll be writing about wrapper classes in my future articles.
> ### You must know that there are more than 3 billion devices that run Java
![bigno.jpg](https://cdn.hashnode.com/res/hashnode/image/upload/v1622436422787/fgqEFjQAW.jpeg)
Yes according to Oracle three billion devices run Java. Java just keeps getting better with age.

### Is java a Compiled language only?
![no.jpg](https://cdn.hashnode.com/res/hashnode/image/upload/v1622436178065/79ZXwsG9G.jpeg)
Java is not a compiled language only, it is both compiled and interpreted, it is first compiled by Java compiler and a byte code is generated then this byte code is interpreted and runs on the JVM.  Where Java differs from others, is that it can be run on any computer platform without having to be re-compiled. 
>### Here comes the principle of portability
So Java language is portable or to be more precise byte code is portable. This byte code you can run on any other machine that has a compliant JVM. The source code does not have to be changed to meet the particular needs of a particular computer systems. No matter what computer you have, you can write the same Java programs. This will be more clear once you complete reading this article.

## It's right time to know about JDK, JVM & JRE
![jdk.jpg](https://cdn.hashnode.com/res/hashnode/image/upload/v1622451984188/trBhvp9HK.jpeg)
### What is JDK?
**Java Development Kit** (JDK) is a bundle of software development tools and supporting libraries combined with the Java Runtime Environment (JRE) and Java Virtual Machine (JVM). The latest version is JDK 16. It is possible to install more than one JDK version on the same computer. It contains development tools such as a compiler, debugger, etc. It also includes Java application launcher, Appletviewer, etc.

### What is JRE?
**Java Run-time Environment** (JRE) is a software platform where all the Java source codes are executed. It is a set of tools using which the JVM actually runs. JRE is responsible for integrating the software plugins, jar files, and support libraries necessary for the source code to run. It contains the class libraries, loader class, and JVM. It is used to dynamically link native methods, manage memory, and handle exceptions. It includes integration libraries like Java Database Connectivity (JDBC), Remote Method Invocation (RMI) and more.

### What is JVM?
**Java Virtual Machine** (JVM) is a software tool responsible for creating a run-time environment for the Java source code to run. It converts Java bytecode into machine language. We know that the Portability feature of Java is made possible by JVM. To install JVM, you need to install JRE. It enables you to run applications in a cloud environment or in your device. It can be called Interpreter because it executes program line by line. 

>#### Class Loader:-
It makes sure that all the necessary classes are loaded in the time of execution of a program. It performs three major functions Loading, Linking, and Initialization. 
#### Automatic Garbage Collection:-
![garbage-collector.jpg](https://cdn.hashnode.com/res/hashnode/image/upload/v1622460940400/_oBKoYr3KB.jpeg)
It is the process by which Java programs perform automatic memory management. It is the process of reclaiming the runtime unused memory by destroying the unused objects. Programmers working in languages without garbage collection (like C and C++) must implement manual memory management in their code.


### Okay so that's enough for now I'll be writing more about basic concepts of Java in my next article, follow my this journey to learn more about Java.
#### *Thank you for reading.*
#### *Please share your thoughts about it and correct me if I'm wrong.*
#### *I hope you liked it and found it helpful.*
#### ***Cover:- [Rajat Gour](https://twitter.com/rajatgour20)***
#### *Connect with me on [Twitter](https://twitter.com/ritvikdubey27?s=09) or [LinkedIn](https://www.linkedin.com/in/ritvik-dubey-3bbb22169)*
#### *My personal blog [blog.ritvikdubey.com](https://blog.ritvikdubey.com/)*