Heapq
Support heaps, data objects where each node is either greater than or equal to its parent (max-heap) or less than or equal to its parent (min-heap) Create a heap from {iterable}
heapq.heapify(iterable)
heapq.heappop(heap)
heapq.heapreplace(heap,element)