This category is for logical grouping only. It needn’t to be added directly. Instead, the sub-categories should be added.

## Sum of XOR of all subarrays

Given an array containing N positive integers, the task is to find the sum of XOR of all sub-arrays of the array. Examples: Input :… Read More »

## Find the longest Fibonacci-like subarray of the given array

Given an array of N elements, the task is to find the longest subarray which is Fibonacci-like. A Fibonacci-like sub-array is defined as an array… Read More »

## Queries for number of distinct integers in Suffix

Given an array of N elements and Q queries, where each query contains an integer K. For each query, the task is to find the… Read More »

## DP on Trees | Set-3 ( Diameter of N-ary Tree )

Given an N-ary tree T of N nodes, the task is to calculate the longest path between any two nodes(also known as the diameter of… Read More »

## Print all internal nodes of a Binary tree

Given a Binary tree, the task is to print all the internal nodes in a tree. An internal node is a node which carries at… Read More »

## Delete nodes which have a greater value on right side using recursion

Given a singly linked list, remove all the nodes which have a greater value on the right side. Examples: a) The list 12->15->10->11->5->6->2->3->NULL should be… Read More »

## Source to destination in 2-D path with fixed sized jumps

Given the source point and the destination point of the path and two integers x and y. The task is to check whether it is… Read More »

## Minimize the sum of the squares of the sum of elements of each group the array is divided into

Given an array consisting of even number of elements, the task is to divide the array into M group of elements (every group must contain… Read More »

## Merge K sorted arrays | Set 3 ( Using Divide and Conquer Approach )

Giving k sorted arrays, each of size N, the task is to merge them into a single sorted array. Examples: Input : arr[][] = {{5,… Read More »

## Maximum length subsequence such that adjacent elements in the subsequence have a common factor

Given an array arr[], the task is to find the maximum length of a subsequence such that the adjacent elements in the subsequence have a… Read More »

## Check if a string can be converted to another string by replacing vowels and consonants

Given two strings S1 and S2, you are allowed only to change a character at any position to any vowel if it is a vowel… Read More »

## Count of pairs (x, y) in an array such that x < y

Given an array of N distinct integers, the task is to find the number of pairs (x, y) such that x < y. Example: Input:… Read More »

## Reverse zigzag Traversal of a Binary Tree

Given a Binary Tree, the task is to print the Reverse zigzag Order of the tree. Examples: Input: 1 / \ 2 3 / \… Read More »

## Count of words that are present in all the given sentences

Given n sentences. The task is to count the number of words that appear in all of these sentences. Note that every word consists of… Read More »

## Minimize the sum of squares of sum of N/2 paired formed by N numbers

Given N numbers(N is an even number). Divide the N numbers into N/2 pairs in such a way that the sum of squares of the… Read More »