## Find the number of boxes to be removed

Given an array arr[] representing a sequence of piles of boxes where each and every box has the same height of 1 unit. Given that… Read More »

## Maximum removal from array when removal time >= waiting time

Given there are N elements in an array. The task is to remove elements from the array from left to right. However, some time is… Read More »

## Minimum number of days required to complete the work

Given N works numbered from 1 to N. Given two arrays D1[] and D2[] of N elements each. Also, each work number W(i) is assigned… Read More »

## Subarray whose absolute sum is closest to K

Given an array of n elements and an integer K, the task is to find the subarray with minimum value of ||a[i] + a[i +… Read More »

## Minimum cost path from source node to destination node via an intermediate node

Given an undirected weighted graph. The task is to find the minimum cost of the path from source node to the destination node via an… Read More »

## Queries to find maximum product pair in range with updates

Given an array of N positive integers. The task is to perform the following operations according to the type of query given. 1. Print the… Read More »

## Minimum steps needed to cover a sequence of points on an infinite grid

Given an infinite grid, initial cell position (x, y) and a sequence of other cell position which needs to be covered in the given order.… Read More »

## Sum of minimum difference between consecutive elements of an array

Given an array of pairs where each pair represents a range, the task is to find the sum of the minimum difference between the consecutive… Read More »

## Sudo Placement[1.3] | Final Destination

Given an array of integers and a number K with initial and final values. Your task is to find the minimum number of steps required… Read More »

## Delete all the nodes from the doubly linked list that are greater than a given value

Given a doubly linked list containing N nodes and a number X, the task is to delete all the nodes from the list that are… Read More »

## Place N^2 numbers in matrix such that every row has an equal sum

Given a number N, place numbers from the range [1, N2] in an NxN matrix such that sum in every row is equal. Examples: Input:… Read More »

## Smallest number in BST which is greater than or equal to N ( Iterative Approach)

Given a Binary Search Tree and a number N, the task is to find the smallest number in the binary search tree that is greater… Read More »

## Lexicographically smallest string formed by appending a character from the first K characters of a given string

Given a string S consisting of lowercase alphabets. The task is to find the lexicographically smallest string X of the same length only that can… Read More »

## Maximum number of ones in a N*N matrix with given constraints

Given two integers and , where . Find the maximum number of one’s in a binary matrix can have such that every sub-matrix of size… Read More »

## Longest string in non-decreasing order of ASCII code and in arithmetic progression

Given a non-empty string S of uppercase alphabets of length L and the task is to find the longest string from the given string with… Read More »