BatHeapSourceFunctional heaps over ordered types
Ascribes to:
BatEnum.Enumerable with type 'a enumerable = 'a t
Heap of elements that are compared with Pervasives.compare.
add x h is the same as insert h x. This function is intended to be used with fold_right.
Build a heap from an enumeration. Consumes the enumeration. O(n log n)
Enumerate the elements of the heap in heap order. O(log n) per BatEnum.get.
val print :
?first:string ->
?last:string ->
?sep:string ->
('a, 'b) BatIO.printer ->
('a t, 'b) BatIO.printerPrint the contents of the heap in heap order. O(n log n)