/// <summary>
 /// Extract the smallest element.
 /// </summary>
 /// <exception cref="InvalidOperationException"></exception>
 public KeyValuePair <TKey, TValue> ExtractMin()
 {
     return(heap.ExtractMin());
 }
Exemple #2
0
 /// <summary>
 /// Extract the largest element.
 /// </summary>
 /// <exception cref="InvalidOperationException"></exception>
 public T ExtractMax() => minHeap.ExtractMin();