GATE | GATE CS 2008 | Question 47
We have a binary heap on n elements and wish to insert n more elements (not necessarily one after another) into this heap. The total time required for this is
(A)Â (logn)
(B)Â (n)
(C) (nlogn)
(D) (n^2)
(A) A
(B) B
(C) C
(D) D
Answer: (B) Explanation: See
https://www.geeksforgeeks.org/data-structures-and-algorithms-set-14/ for explanation
Quiz of this Question
Last Updated :
28 Jun, 2021
Like Article
Save Article
Share your thoughts in the comments
Please Login to comment...