About Trees, different Traversals and BST
A tree is a data structure made up of nodes or vertices and edges without having any cycle. The tree with no nodes is called the null or empty tree. A tree that is not empty consists of a root node and potentially many levels of additional nodes that form a hierarchy. Tree Tree Terminology Lets see some tree terminologies:- Root: The top node in a tree. Child: A node directly connected to another node when moving away from the Root. Parent: The converse notion of a child. Siblings: A group of nodes with the same parent. Descendant: A node reachable by repeated proceeding from parent to child. Ancestor: A node reachable by repeated proceeding from child to parent. Leaf: A node with no children. Internal node: A node with at least one child. Degree: The number of sub trees of a node. Edge: The connection between one node and another. Path: A sequence of nodes and edges connecting a node with a descendant. Level: The level of a node is defined by 1 + (the...