We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Which of these is the time complexity involved in building a heap of n elements - and cannot be expressed in lower order terms ?
How come the answer is not o(nlogn)? If you are talking about heap then it must be min heap or max heap.Max/Min heapify takes o(log(n)).So it should be o(nlogn).Please let me know if i am missing something.
A Basic Quiz on Algorithms #1
You are viewing a single comment's thread. Return to all comments →
Which of these is the time complexity involved in building a heap of n elements - and cannot be expressed in lower order terms ? How come the answer is not o(nlogn)? If you are talking about heap then it must be min heap or max heap.Max/Min heapify takes o(log(n)).So it should be o(nlogn).Please let me know if i am missing something.