+1 vote
in Data Structures & Algorithms I by (110k points)
Which node is the Leaf node in the following ternary tree?

(a) A

(b) B

(c) D

(d) G

My enquiry is from 1 in portion Trees of Data Structures & Algorithms I

This question was addressed to me in an interview.

1 Answer

+1 vote
by (672k points)
selected by
 
Best answer
The correct answer is (d) G

The best I can explain: Leaf node is any node that does not contain any children. Since Node G is the node without any children, So G is called Leaf Node. While Node A is root node and Node B, Node C, Node D is parent node of their children.

Related questions

Welcome to TalkJarvis QnA, a question-answer community website for the people by the people. On TalkJarvis QnA you can ask your doubts, curiosity, questions and whatever going in your mind either related to studies or others. Experts and people from different fields will answer.

Categories

...