Question: In a min-heap, which of the following is true?
Options:
The root is the smallest element
The root is the largest element
All parent nodes are smaller than their children
Both A and C
Correct Answer: Both A and C
Solution:
In a min-heap, the root is the smallest element, and all parent nodes are smaller than their children.
In a min-heap, which of the following is true?
Practice Questions
Q1
In a min-heap, which of the following is true?
The root is the smallest element
The root is the largest element
All parent nodes are smaller than their children
Both A and C
Questions & Step-by-Step Solutions
In a min-heap, which of the following is true?
Min-Heap Properties – A min-heap is a complete binary tree where the value of each node is less than or equal to the values of its children, ensuring the smallest element is at the root.
Soulshift Feedback×
On a scale of 0–10, how likely are you to recommend
The Soulshift Academy?