Basic Definition of Binary Trees, Properties of Binary Trees, Representation of Binary Trees

 


Binary Tree is defined as a tree data structure where each node has at most 2 children. Since each element in a binary tree can have only 2 children, we typically name them the left and right child.Binary Tree is defined as a tree data structure where each node has at most 2 children. Since each element in a binary tree can have only 2 children, we typically name them the left and right child.

Binary Tree Representation


A Binary tree is represented by a pointer to the topmost node (commonly known as the “root”) of the tree. If the tree is empty, then the value of the root is NULL. Each node of a Binary Tree contains the following parts:

  1. Data
  2. Pointer to left child
  3. Pointer to right child


No comments:

Post a Comment