Binary tree is a special type of data structure that has collection of elements known as nodes. The topmost node is called parent node. Each node has either zero, one or two child nodes. A node with zero children is called Leaf Node or Terminal Node.
In this article, we will explore the algorithm to check if a Binary Tree is balanced by height or not.
Terminologies:
Based on below image let us understand some important terminologies:
1. Parent :
If any node has a child node on left and/or right...
Published on January 22, 2021 04:38