+1 vote
in Data Structures & Algorithms I by (110k points)
Which node has the lowest priority in a treap?

(a) root node

(b) leaf node

(c) null node

(d) centre node

The query is from Binary Trees topic in chapter Binary Trees of Data Structures & Algorithms I

I got this question during a job interview.

1 Answer

+1 vote
by (672k points)
selected by
 
Best answer
Right choice is (a) root node

The best explanation: A root node has the lowest priority in a treap since the node’s priority is based on heap order.

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

...