Skip to content

Tag Archives: Inorder Traversal

Given a binary tree consisting of distinct values and two numbers K1 and K2, the task is to find all nodes that lie between them… Read More
Given two Binary Search Tree (BSTs) and a value X, the problem is to print all pairs from both the BSTs whose sum is greater… Read More
Given a Binary Search tree and an integer K, we have to split the tree into two Balanced Binary Search Tree, where BST-1 consists of… Read More
Given an N-ary tree containing, the task is to print the inorder traversal of the tree. Examples:  Input: N = 3   Output: 5 6 2… Read More
Given a Binary Tree, the task is to check whether the given binary tree is Binary Search Tree or not.A binary search tree (BST) is… Read More
Given Inorder traversal and Level Order traversal of a Binary Tree. The task is to calculate the height of the tree without constructing it. Example:… Read More
Given a Binary Search Tree (BST), the task is to print the BST in min-max fashion. What is min-max fashion? A min-max fashion means you… Read More
Given a binary tree. The task is to find out the maximum and minimum element in a binary tree without using recursion or stack or… Read More
Given a tree and a node, the task is to reverse the path till the given Node and print the in-order traversal of the modified… Read More
Given a complete binary tree, the task is to find the sum of mirror image nodes in an inorder way i.e. find the inorder traversal… Read More
Given a Perfect Binary Tree, the task is to reverse the alternate level nodes of the binary tree.Examples: Input: a / \ b c /… Read More
Given a tree having every node’s value as either 0 or 1, the task is to find whether the given binary tree contains any sub-tree… Read More
Given a Binary Tree. The task is to find the maximum value among all of the right child nodes of the Binary Tree. Note: If… Read More
Given a binary tree. First print all leaf nodes, after that remove all the leaf nodes from the tree and now print all the new… Read More
Given a Binary tree, the task is to sort the particular path from to a given node of the binary tree. You are given a… Read More