## Generate Complete Binary Tree in such a way that sum of non-leaf nodes is minimum

Given an array arr[] of size N, the task is to generate a Complete Binary Tree in such a way that sum of the non-leaf… Read More »

- Real-time application of Data Structures
- Stack of Pair in C++ STL with Examples
- C/C++ program for calling main() in main()
- Important functions of STL Components in C++
- Maximize sum of topmost elements of S stacks by popping at most N elements
- Min difference between maximum and minimum element in all Y size subarrays
- Range Sum and Update in Array : Segment Tree using Stack
- Generate Complete Binary Tree in such a way that sum of non-leaf nodes is minimum
- Static and Dynamic data structures in Java with Examples
- Append the elements of queue in mirror-inverse order
- Program to convert Infix notation to Expression Tree
- Minimum steps required to make an array decreasing
- Check whether there exists a triplet (i, j, k) such that arr[i] < arr[k] < arr[j] for i < j < k
- Difference between Stack and Array
- Sort array such that absolute difference of adjacent elements is in increasing order
- Print all K-sum levels in a Binary Tree
- Maximum of XOR of first and second maximum of all subarrays
- Output of Java Programs | Set 55 (Java Collections Framework)
- Reverse the elements only at odd positions in the given Array
- Level order traversal in spiral form using stack and multimap
- Calculate weight of parenthesis based on the given conditions
- Find cells in Matrix that are not visited by Robot for given movements
- Find number of subarrays ending with arr[i] where arr[i] is the minimum element of that subarray
- Change the given string according to the given conditions
- Unique subsequences of length K with given sum
- Minimum operation required to make a balanced sequence
- Check if a string can be split into even length palindromic substrings
- Sum of decomposition values of all suffixes of an Array
- Stack machine in Computer Organisation
- Difference between Array, Queue and Stack

Given an array arr[] of size N, the task is to generate a Complete Binary Tree in such a way that sum of the non-leaf… Read More »

Stack in STL Stacks are a type of container adaptors with LIFO(Last In First Out) type of working, where a new element is added at… Read More »

Given an array, arr[] of size N, the task is to find the number of sub-arrays ending with arr[i] and arr[i] is the minimum element… Read More »

Instruction formats are classified into different types depending upon the CPU organization. CPU organization is again classified into three types based on internal storage: Stack… Read More »

Given an integer N, the task is to find the minimum integer that can be obtained from the given integer such that the adjacent digits… Read More »

Given an array arr[] of distinct positive elements, the task is to find the number of unique pairs (a, b) such that a is the… Read More »

Given an expression as a string str consisting of numbers and basic arithmetic operators(+, -, *, /), the task is to solve the expression. Note… Read More »

Given an N * M matrix mat[][], the task is to find the area-wise largest rectangular sub-matrix such that each column and each row of… Read More »

Given an array arr[] of N distinct positive integers, let’s denote max(i, j) and secondMax(i, j) as the maximum and the second maximum element of… Read More »

Given a string str that consists of lower case English letters and brackets. The task is to reverse the substrings in each pair of matching… Read More »

Given an N-ary tree, the task is to find the post-order traversal of the given tree iteratively. Examples: Input: 1 / | \ 3 2… Read More »

Given a string str consisting of lowercase and uppercase characters, the task is to find the minimum possible length the string can be reduced to… Read More »

Given a stack of integers and an integer K, the task is to sort the elements of the given stack using another stack in the… Read More »

Given a bracket sequence as a string str, the task is to find whether the given string can be balanced by moving at most one… Read More »

Given N ranges [L, R] and an integer K, the task is to check if there are any K ranges which overlap at any point.… Read More »