(heap: Heap<T>)
| 21 | } |
| 22 | |
| 23 | export function peek<T: Node>(heap: Heap<T>): T | null { |
| 24 | return heap.length === 0 ? null : heap[0]; |
| 25 | } |
| 26 | |
| 27 | export function pop<T: Node>(heap: Heap<T>): T | null { |
| 28 | if (heap.length === 0) { |
no outgoing calls
no test coverage detected