@heap-data-structure/binomial-heap
v12.0.0
Published
Binomial heap data structures for JavaScript
Downloads
5
Readme
:cherries: @heap-data-structure/binomial-heap
Binomial heap data structures for JavaScript. See docs. Parent is @heap-data-structure.
//
// o o o--. o
// |\ |\ |\ \ /|\
// o o + o o = o o o = o o o
// | | | |\ | |\
// o o o o o o o o
// | |
// o o
//
import {
BinomialHeap,
LazyBinomialHeap,
BinomialTree,
BinomialTreeWithParent,
} from '@heap-data-structure/binomial-heap';
import {increasing} from '@total-order/primitive';
let heaps = [
new ( BinomialHeap( BinomialTreeWithParent ) )( increasing ) ,
new ( BinomialHeap( BinomialTree ) )( increasing ) ,
new ( LazyBinomialHeap( BinomialTree ) )( increasing ) ,
new ( LazyBinomialHeap( BinomialTreeWithParent ) )( increasing ) ,
] ;
:scroll: Reference
- http://www.cs.princeton.edu/~wayne/cs423/lectures/heaps-4up.pdf