Category Archives: Java

Immutable object in Java- How to create immutable object in Java?

By | June 18, 2025

In Java, immutable objects are objects whose state cannot be changed once they are created; they will remain constant throughout the lifecycle of the object. It helps in terms of simplicity, thread-safety and security. For example, string objects, In Java, string objects are immutable. i.e., once they are initialized, they cannot be changed. To learn… Read More: Immutable object in Java- How to create immutable object in… »

How to convert Java class file to source code

By | October 2, 2025

Java Decompiler A Java decompiler is a reverse engineering tool that can be used to convert Java bytecode back to Java source code. It became useful when we had the compiled Java classes (in the form of bytecode, typically stored in a.class file) but not the original source code. In this tutorial, we will learn… Read More: How to convert Java class file to source code »

Multithreading in Java Real time example

By | December 7, 2023

What is Multithreading in Java? In multithreading, a program is divided into two or more subprograms or threads that can run concurrently (at the same time) in parallel or concurrently in a shared memory space. Each thread represents a separate flow of control within the program, allowing multiple operations to be performed simultaneously. Multithreading is… Read More: Multithreading in Java Real time example »

Java 21 – Java 21 features with example

By | March 3, 2024

The new version of Java, Java 21, is finally released on September 19, 2023, as the next long-term support (LTS) version. Because of this LTS version, it will be used in commercial support as the next stable version. After working on a total of 2585 JIRA issues, of which 1868 were resolved by Oracle and… Read More: Java 21 – Java 21 features with example »

How to resolve Eclipse version 1.8.0_301 of the JVM is not suitable for this product. Version 17 or greater is required. | Eclipse JVM is not suitable for this product

By | December 28, 2024

Whenever we install a new version of Eclipse IDE, which comes with the latest support for JVM, while opening Eclipse IDE, we may get the following error: Version 1.8.0_301 of the JVM is not suitable for this product. Version 17 or greater is required. Steps to resolve JVM version 17 or greater is required Step… Read More: How to resolve Eclipse version 1.8.0_301 of the JVM is… »

Internal working of System.out.println in Java

By | October 23, 2024

In Java, System.out.println() is a statement that is used to print the arguments passed to it to the standard output, typically a console window. Let us understand System.out.println in Java in detail: System in Java System is a predefined final class present in the java.lang package. It is automatically imported in every Java program, we… Read More: Internal working of System.out.println in Java »

Yoda condition | if(null == x) or if(x == null)?

By | November 10, 2024

Yoda Condition: Good or Bad The term Yoda condition refers to a standard programming practice that says we must reverse the typical order of a conditional statement in code. It is named after the Star Wars character Yoda, who speaks in a unique way, where he switches the order of subjects and verbs in his… Read More: Yoda condition | if(null == x) or if(x == null)? »

Java Memory Management: Ultimate Guide for Performance and Optimization

By | August 25, 2023

Java Memory management in Java refers to the process of handling computer memory (RAM) effectively and efficiently to store and manage objects created during the execution of a Java program. It involves allocating memory to new objects when they are created and freeing up memory from objects that are no longer needed (garbage collection) to… Read More: Java Memory Management: Ultimate Guide for Performance and Optimization »

Why use the char[] array for storing passwords over strings in Java?

By | June 18, 2025

A string is an object in Java that represents a sequence of character values. Strings are immutable, which means once they are created, we cannot change their value. It is recommended to use the char[] array for storing passwords over strings in Java because of following reasons: 1. Strings are immutable In Java, the memory… Read More: Why use the char[] array for storing passwords over strings… »