Binary search tree

A binary search tree is a binary tree, with the content of all elements in the left subtree of a node are lesser than the content in the parent. Whereas all nodes content in its right subtree are greater than its parent. Let’s see below two example binary search trees. As observed in the aboveRead More »


Level order tree traversal

Other than usual pre, post, and in-order binary tree traversals. There are other ways to traverse a binary tree. We will see level order traversals in this article. In the level order traversal, tree nodes process level by level. There are two ways to solve this level order traversal problem. Recursive Approach In this approach,Read More »