Sealed class in Java

In Java, to prevent the inheritance of a certain class, we will use the final keyword to declare that class. Examples are as follows:

Class Test will not be able to inherit JavaExample class because this JavaExample class is declared with final: A need… Read More

Nested class in Java

Java allows us to define a class that belongs to another class, for example:

Class is defined inside another class, we call it nested class and this other class is called outer class. In my example above, the Builder is a nested class and… Read More

Introduce about text block in Java

Previously, when declaring a multi-line text in Java, for example:

We will usually declare the following:

Result: But from Java 13 onwards, you do not need to declare so anymore. Java now supports the text blocks with the ability to declare multiple lines… Read More

Install Java JDK

To work with the Java programming language, the first thing you need to do is set up the environment to run the application with the Java JDK. In this article, I will guide you through the steps to install Java JDK! To install Java JDK,… Read More