Binary Heap - Heap Operations

Heap Operations

Both the insert and remove operations modify the heap to conform to the shape property first, by adding or removing from the end of the heap. Then the heap property is restored by traversing up or down the heap. Both operations take O(log n) time.

Read more about this topic:  Binary Heap

Famous quotes containing the words heap and/or operations:

    We must heap up a great pile of doing, for a small diameter of being.
    Henry David Thoreau (1817–1862)

    You can’t have operations without screams. Pain and the knife—they’re inseparable.
    —Jean Scott Rogers. Robert Day. Mr. Blount (Frank Pettingell)