## 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 »

- How can one become good at Data structures and Algorithms easily?
- How do Dynamic arrays work?
- Find the node with maximum value in a Binary Search Tree
- Remove last node of the linked list
- Iterative Method To Print Left View of a Binary Tree
- Sort the array of strings according to alphabetical order defined by another string
- Fibonacci Heap - Deletion, Extract min and Decrease key
- Zig-Zag traversal of a Binary Tree using Recursion
- Number of array elements derivable from D after performing certain operations
- Print all nodes between two given levels in Binary Tree
- Sum of nodes at maximum depth of a Binary Tree | Set 2
- Print all odd nodes of Binary Search Tree
- Number of subarrays have bitwise OR >= K
- Reverse zigzag Traversal of a Binary Tree
- Count all Grandparent-Parent-Child Triplets in a binary tree whose sum is greater than X
- Number of sub-strings which are anagram of any sub-string of another string
- A variation of Rat in a Maze : multiple steps or jumps allowed
- Difference between Stack and Queue Data Structures
- Sum and Product of minimum and maximum element of Binary Search Tree
- Minimum number of edges between two vertices of a graph using DFS
- Building Expression tree from Prefix Expression
- Print All Leaf Nodes of a Binary Tree from left to right | Set-2 ( Iterative Approach )
- Sum of minimum elements of all possible sub-arrays of an array
- Delete all odd or even positioned nodes from Circular Linked List
- Sum of all the elements in an array divisible by a given number K
- Sum and Product of the nodes of a Circular Singly Linked List which are divisible by K
- Find maximum among all right nodes in Binary Tree
- Finding the path from one vertex to rest using BFS
- Product of all nodes in a Binary Tree
- Multidimensional Collections in Java

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 »

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 »

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 »

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 »

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 »

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 »

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 »

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 »

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 »

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 »

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 »

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 »

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

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 »

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 »