## Level Order Successor of a node in Binary Tree

Given a binary tree and a node in the binary tree, find Levelorder successor of the given node. That is, the node that appears after… Read More »

- Level order traversal of Binary Tree using Morris Traversal
- Sum of all nodes at Kth level in a Binary Tree
- Boundary Level order traversal of a Binary Tree
- Specific Level Order Traversal of Binary Tree
- Diamond Tree
- Deletion of a given node K in a Binary Tree using Level Order Traversal
- Print all Exponential Levels of a Binary Tree
- Maximum absolute difference between any two level sum in a Binary Tree
- Construct a Binary in Level Order using Recursion
- Check if max sum level of Binary tree divides tree into two equal sum halves
- Print all K-sum levels in a Binary Tree
- Iterative Approach to check if two Binary Trees are Isomorphic or not
- Print all Palindromic Levels Of a Binary Tree
- Print all Co-Prime Levels of a Binary Tree
- Count of nodes in a Binary Tree whose child is its prime factors
- Check if the Left View of the given tree is sorted or not
- Count of nodes in a Binary Tree whose immediate children are co-prime
- Print all nodes except rightmost node of every level of the Binary Tree
- Count of nodes in a Binary tree with immediate children as its factors
- Print all Prime Levels of a Binary Tree
- Replace every node with depth in N-ary Generic Tree
- Largest number possible by arranging node values at each level

Given a binary tree and a node in the binary tree, find Levelorder successor of the given node. That is, the node that appears after… Read More »

Given a binary tree and a node in the binary tree, find Levelorder Predecessor of the given node. That is, the node that appears before… Read More »

Given a tree, with N nodes and E edges (every edge is denoted by two integers, X, Y stating that X is the parent of… Read More »

Top view of a binary tree is the set of nodes visible when the tree is viewed from the top. Given a binary tree, print… Read More »

Given the root of a binary tree and a key x in it, find the distance of the given key from the root node. Distance… Read More »

Given an array of elements, the task is to insert these elements in level order and construct a tree. Input : arr[] = {10, 20,… Read More »

Write a function to print spiral order traversal of a tree. For below tree, function should print 1, 2, 3, 4, 5, 6, 7. Recommended:… Read More »

Given a binary tree and data value of a node. The task is to find the sum of cousin nodes of given node. If given… Read More »

Given a binary tree and a node, print all cousins of given node. Note that siblings should not be printed. Examples: Input : root of… Read More »

Given a root node to a tree, find the sum of all the leaf nodes which are at maximum depth from root node. Example: 1… Read More »

Given a binary tree, flatten it into linked list in-place. Usage of auxiliary data structure is not allowed. After flattening, left of each node should… Read More »

Given a binary tree and the two nodes say ‘a’ and ‘b’, determine whether two given nodes are cousins of each other or not. Two… Read More »

Given a binary tree. The task is to check if the binary tree is sorted level-wise or not. A binary tree is level sorted if… Read More »

Given a Binary Tree having positive and negative nodes, the task is to find maximum product level in it. Examples: Input : 4 / \… Read More »