Open In App

GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 49

Like Article
Like
Save
Share
Report

Consider the following statements:

I. The number of possible min-heaps containing each value from 7 indistinguishable element is 80.
II. A max-heap can be constructed from a binary search tree in Θ(n) time.
III. The kth smallest element in a max-heap can be found in O(log n) time.
IV. A binary search tree can be constructed from a max-heap in O(n log n) time.

Which of the above statements is/are TRUE ?
(A) II, III and IV
(B) I, II and III
(C) I, III and IV
(D) I, II and IV


Answer: (A)

Explanation: When elements are not distinguishable, then only one heap exists.

Option (A) is correct.

Quiz of this Question


Last Updated : 24 Dec, 2019
Like Article
Save Article
Previous
Next
Share your thoughts in the comments
Similar Reads