## Heap in Data Structure

In Data Structure a Heap is a Binary tree in which all levels have a maximum number of nodes except possibly the last level and in the last level all the nodes are to the left and the key in any node is greater than or equal to the keys in both children of the…