Hi,

https://dlang.org/phobos/std_container_binaryheap.html

The binary heap induces structure over the underlying store such that accessing the largest element (by using the front property) is a Ο(1) operation.

I'm wondering what's the most efficient (in terms of both speed and memory usage) way to implement std.container.binaryheap.back()? i.e accessing the smallest element.

Has anyone done this before?

Thanks.

Reply via email to