ID EN
Heapq

heappush

Python 3.11

Push the value item onto the heap, maintaining the heap invariant.

Syntax

PYTHON
heapq.heappush(heap, item)