Java is a popular programming language, created in 1995.It is owned by Oracle, and more than 3 billion devices run Java. It is used for:
We created a Java file called Main.java, and we used the following code to print "Hello World" to the screen:
public class Main {
public static void main(String[] args) {
System.out.println("Hello, World!");
}
}
Data types are divided into two groups:
A primitive data type specifies the size and type of variable values, and it has no additional methods.There are eight primitive data types in Java:
Non-primitive data types are called reference types because they refer to objects.