On Thursday, 6 August 2015 at 09:08:04 UTC, John Colvin wrote:
Worst case for getting root off a binary heap is O(log(N)), copying the whole thing is O(N).

Those numbers does not take into account the special properties of *in-array-packed* implementation of a binary heap. They are *theoretical properties* related to a graph implementation of a `BinaryHeap`.

The important thing in our D case is *which elements* in the array that needs to be changed or *moved*.

Reply via email to