|
Functions |
| Heap_t * | Heap_InitN (int(*less)(char *, char *), int N) |
| | Create a heap with N entries.
|
| Heap_t * | Heap_Init (int(*less)(char *, char *)) |
| | Create a heap with 0 entries.
|
| void | Heap_Insert (Heap_t *aHeap, char *entry) |
| | Insert an entry into a heap.
|
| int | Heap_Size (Heap_t *aHeap) |
| | Returns the number of elements in the heap.
|
| char * | Heap_ReadMax (Heap_t *aHeap) |
| | Return the max element of the heap; does not change heap.
|
| void | Heap_Heapify (Heap_t *aHeap) |
| | Take a heap which satisfies the heap property everywhere but possibly the root, and make it into a heap.
|
| int | Heap_Test () |
| | Code to test the heap package.
|
Array starts at zero, so left and right children are at (2*index + 1) and ( 2 * index + 2 ).