12 ms·
heapq exposes a minheap by default, but there is a maxheap as well that for some reason, is not exposed! Just do heapq._heapify_max
by somezero 5y ago
heapq exposes a minheap by default, but there is a maxheap as well that for some reason, is not exposed! Just do heapq._heapify_max