DEV Community

Discussion on: Fast priority queues in Golang: Hierarchical Queue

Collapse
 
theodesp profile image
Theofanis Despoudis

Cool. How does this compare to Pairing heaps or Fibonacci heaps?

Collapse
 
bgadrian profile image
Adrian B.G.

Those heaps have O(log n) for delete-min (dequeue), this one has constant time for every operation, but as I said in the article, it has limitations.

A Heap has to move some values around after a delete is done, as in here, you only have to popup from a queue.