Pike v8.0 release 1738

Method ADT.Heap()->push()


Method push

Element push(mixed value)

Description

Push an element onto the heap. The heap will automatically sort itself so that the smallest value will be at the top.

Returns

Returns an element handle, which can be used with adjust() and remove().

Note

If value is a Heap.Element and already present on the heap this is equivalent to calling adjust().

See also

pop(), remove()