Skip to content

Category Archives: Java Programs

Given a decimal number N, convert N into an equivalent octal number i.e convert the number with base value 10 to base value 8. The… Read More
This article will guide you through the process of printing a Pyramid star pattern in Java. 1. Simple pyramid pattern Java import java.io.*;   //… Read More
In this article, we will learn about printing Left Triangle Star Pattern. Examples: Input : n = 5 Output: * * * * * *… Read More
In this article, we will learn about printing Right Triangle Star Pattern. Examples: Input : n = 5 Output: * * * * * *… Read More
Given a number n as the size of the matrix, the task is to print a spiral pattern of size n. Examples: Input : n… Read More
Primarily, java does not have any function or package that will create a password-protected zip file without using some native codes. Java has some useful… Read More
The HashSet class implements the Set interface, backed by a hash table which is a HashMap instance. There is no assurance as to the iteration… Read More
The Heap area is one of the various memory areas present inside the JVM.  For every JVM one heap area is available. The Heap area… Read More
A hash table is a data structure that executes a connected array, it is a structure that maps keys to its values. It uses a… Read More
In order to define a date and time, the DateTime data type is used. DateTime is defined in the format as “YYYY-MM-DDThh:mm:ss” where: YYYY states… Read More
A shell command is a command that we can trigger using a keyboard and a command-line or a shell instead of a Graphical user interface.… Read More
In java, we have a java.io package that provides various methods to perform various operations on files/directories.  Temporary files are those files that are created… Read More
A leftist heap is a priority Queue implemented with a binary heap. Every node has a sValue which is at the nearest Distance to the… Read More
As we know that the HashSet contains only unique elements, ie no duplicate entries are allowed, and since our aim is to remove the duplicate… Read More
We need to calculate a number raised to the power of some other number without using the predefined function java.lang.Math.pow() In Java, we can calculate… Read More

Start Your Coding Journey Now!