Results for “Std.Heap.Heap”
18 matching declarations
Use module:Std.List, kind:fn, or is:exact. Put a Pudu type after ::.
- Std.Heap.Heap
A collection that always knows its smallest element.
- Std.Heap.contains
&Std.Heap.Heap[T] -> T -> Bool where T: EqWhether an element is present.
- Std.Heap.dropMin
&Std.Heap.Heap[T] -> Std.Heap.Heap[T] where T: OrdThe heap without its smallest element, unchanged when it is empty.
- Std.Heap.empty
Std.Heap.Heap[T]A heap with nothing in it.
- Std.Heap.filter
&Std.Heap.Heap[T] -> fn(T) -> Bool -> Std.Heap.Heap[T] where T: OrdA heap of every element that satisfies a test.
- Std.Heap.fromArray
&Array[T] -> Std.Heap.Heap[T] where T: OrdA heap holding every element of an array.
- Std.Heap.isEmpty
&Std.Heap.Heap[T] -> BoolWhether the heap holds nothing.
- Std.Heap.map
&Std.Heap.Heap[A] -> fn(A) -> B -> Std.Heap.Heap[B] where B: OrdA heap of every element transformed.
- Std.Heap.merge
&Std.Heap.Heap[T] -> &Std.Heap.Heap[T] -> Std.Heap.Heap[T] where T: OrdTwo heaps joined into one.
- Std.Heap.one
T -> Std.Heap.Heap[T]A heap of one element.
- Std.Heap.peek
&Std.Heap.Heap[T] -> Option[T]The smallest element, or
Nonefor an empty heap. - Std.Heap.pop
&Std.Heap.Heap[T] -> Option[(T, Std.Heap.Heap[T])] where T: OrdThe smallest element and the heap without it, or
Nonewhen empty. - Std.Heap.push
&Std.Heap.Heap[T] -> T -> Std.Heap.Heap[T] where T: OrdThe heap with an element added.
- Std.Heap.size
&Std.Heap.Heap[T] -> IntHow many elements the heap holds.
- Std.Heap.smallest
&Std.Heap.Heap[T] -> Int -> Array[T] where T: OrdThe smallest few elements, in order.
- Std.Heap.toArray
&Std.Heap.Heap[T] -> Array[T]Every element, in no particular order beyond the smallest being reachable.
- Std.Heap.toSortedArray
&Std.Heap.Heap[T] -> Array[T] where T: OrdEvery element, smallest first.
- Std.Heap.union
&Std.Heap.Heap[T] -> &Std.Heap.Heap[T] -> Std.Heap.Heap[T] where T: OrdTwo heaps' elements in one heap.
