Explore topic-wise InterviewSolutions in .

This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.

1.

What is the ancestor of the leaf node in a given minimum ternary heap?(a) 1(b) 10(c) 18(d) 20

Answer»

Correct choice is (a) 1

For explanation: Minimum TERNARY heap has the smallest element as its root node. The PARENT node is all either equal or less than children node in a minimum ternary heap. Ancestor is the node falling on the PATH from that node to the root node. So here ancestor of all LEAF NODES is 1.