# Tag Archives: Binary Tree

Given a Binary Tree consisting of N nodes and a integer K, the task is to find the depth and height of the node with… Read More
Given an infinite complete binary tree rooted at node 1, where every ith node has two children, with values 2 * i and 2 *… Read More
Given an N-ary Tree consisting of N nodes valued from [1, N], where node 1 is the root, the task is to count the pairs… Read More
Given a binary tree consisting of either 1 or 0 as its node values, the task is to find the sum of all vertical levels… Read More
Given a Binary Tree with each node representing an alphabet, the task is to find lexicographically smallest palindromic root to leaf path. If no palindromic… Read More
Given a binary tree, the task is to print all the nodes of the binary tree in Pre-order, Post-order, and In-order iteratively using only one… Read More
Given a Binary Tree consisting of N nodes, the task is to count the number of levels in a Binary Tree such that the set… Read More
Given a Binary Tree and an integer target, denoting the value of a node, the task is to find the sum of distances of all… Read More
Given a binary tree consisting of N nodes, the task is to find the sum of depths of all subtree nodes in a given binary… Read More
Given two Binary trees and two integer keys K1, K2 where both K1, K2 can be present in the same tree or in different trees.… Read More
Given a Binary Tree, the task is to find the smallest subtree that contains all the deepest nodes of the given Binary Tree and return… Read More
Given a Binary Tree consisting of N nodes, the task to find the maximum average of values of nodes of any subtree. Examples:  Input:   … Read More
Given a Binary Tree, the task is to remove the leaf nodes of the Binary Tree during each operation and print the count. Examples: Input:  … Read More
Given a Binary Tree, the task is to check if the given binary tree is a Binary Search Tree or not. If found to be… Read More
Prerequisite: Generic Trees(N-array Trees)  In this article, we will discuss the conversion of the Generic Tree to a Binary Tree. Following are the rules to… Read More