English

Answer the following questions from the diagram of a Binary Tree given below: (i) State the siblings of the nodes C and E. Also, state the predecessor node(s) and successor node(s) of node B. - Computer Science (Theory)

Advertisements
Advertisements

Question

Answer the following questions from the diagram of a Binary Tree given below:

  1. State the siblings of the nodes C and E. Also, state the predecessor node(s) and successor node(s) of node B.  [2]
  2. Write the in-order traversal of the left sub tree and pre-order traversal of the right sub tree.  [2]
Short Answer
Advertisements

Solution

  1. The sibling of node C is B, while the sibling of node E is D. The predecessor of B is D, and its successor is E.
  2. In order traversal of the Left subtree results in: DBGE.
    Preorder traversal of right subtree results in: CFHI
shaalaa.com
  Is there an error in this question or solution?
2021-2022 (March) Official Board Paper
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×