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

Use Lambda Expression to sort elements of a List in Java

Normally, before Java 8, when we want to sort the elements of a List in Java, we will use the Comparator object. Eg:

Result: From Java 8 onwards, we have another way of doing this. That is, using the sort() method of the List… Read More

Components of HotSpot JVM

Java applications run on a Java Virtual Machine (JVM) so understanding how Java applications work in the JVM will help us understand how to organize and write code more efficiently. Currently, we have a variety of JVMs built by different companies based on the JVM… Read More

Constructor reference in Java

I have introduced the method reference in the previous tutorial, in this tutorial, I introduce you another new concept: constructor reference. Like the method reference, the constructor reference is used to abbreviate the Lambda Expression expression. How is it in details? Suppose you are working… Read More