We all have come across the terms of e-trading, stocks etc., right? Well, here this time we have kind of the same problem although don’t worry we won’t be dealing with trading algorithms or that sort. This stock span problem ...

Each element in the linked list is known as a node. A node consists of two parts INFO and POINTER. The work of the INFO part is to store data, whereas the POINTER stores Address of the next node and ...

He has recently secured an internship opportunity with Amazon. Anand is a Computer Science student at VIT Chennai (Batch 2017-21) & pursuing Data Structures & Algorithms with Java course at Coding Ninjas. Let’s take a look at how Anand got ...

The most popular chess game programming problem! Even if you haven’t played chess lets make this easy and simple to understand. This Knight’s tour problem defines that if it is possible to travel all the possible blocks of chess from ...

In this article, we will be going through an interesting problem. Boggle is a word game where players race to find words hidden in a grid of letters. We are given an MxN board where each cell has some character in ...

Linked List is a data structure which is of linear type. This article will help you learn how to solve it in Java. It is a collection of data elements and these data elements are not stored in contiguous fashion ...

Most of the times in programming we tend to have a real-world data structure to implement business logic and functions. One of the most prevailing data structures for this purpose is called a Tree. In basic data structures, we have ...

This is the concept where both count and toggle queries are applied to the binary array. Count Query is used when there is a need to calculate a number of specific bits it appears in any piece of code. We ...

To implement Deque employing a circular array we should track 2 pointer front and rear within the array, all the operations are on these 2 pointers. The which means of circular array will be understood by the image below. In ...

Disjoint Set Union (DSU) is one such data structure. It is also referred to as Union Find because of the functionalities it provides. The efficiency of a data structure depends on efficiently it handles the query of some problem statement. ...