PRASHNIKAप्रश्निका
Back to the paper

Answer the following questions based on the diagram of a Binary Tree given below: Name the external…

Computer Science20243 marksShort answer
Answer the following questions based on the diagram of a Binary Tree given below:
Figure for this question
(a)[1.0]
Name the external nodes of the tree.
(b)[1.0]
State the degree of node M and node L.
(c)[1.0]
Write the post-order traversal of the above tree structure.

Answer

Answer (a)

AI
The external nodes (leaf nodes, i.e. nodes with no children) of the tree are: F, I, C and G.

Answer (b)

AI
Degree of node M (number of children) = 2 (children F and I). Degree of node L (number of children) = 1 (child C).

Answer (c)

AI
Post-order traversal (Left, Right, Root) of the tree: F, I, M, E, C, L, G, H, A
Data structures

From ISC 2024 Computer Science Paper 1, question 11(ii).