- Computer Science Engineering (CSE)
- Data Structures (DS)
- Non Linear Data Structures - Trees
- What is the complexity of adding an elem...

Q. |
## What is the complexity of adding an element to the heap. |

A. | O(log n) |

B. | O(h) |

C. | O(log n) & O(h) |

D. | O(n) |

Answer» C. O(log n) & O(h) |

View all MCQs in:
Data Structures (DS)

- If we implement heap as min-heap, deleting root node (value 1)from the heap. What would be the value of root node after second iteration if leaf node (value 100) is chosen to replace the root at start.
- An array consists of n elements. We want to create a heap using the elements. The time complexity of building a heap will be in order of
- The worst case complexity of deleting any arbitrary node value element from heap is
- In a max-heap, element with the greatest key is always in the which node?
- Heap can be used as
- What is the worst-case time for heap sort to sort an array of n elements?
- For the heap sort, access to nodes involves simple _______________ operations.
- What is the time complexity of searching for an element in a circular linked list?
- What would be the asymptotic time complexity to insert an element at the front of the linked list (head is known)?
- What would be the asymptotic time complexity to find an element in the linked list?

Login to Continue

It will take less than 2 minutes

Report MCQ