public IEnumerable<int> KSE_MinHeap(int[] A, int K){ var heap = new int[K]; for(int i=0; i<heap.Length; i++) heap[i] = A[i]; var pq = new MinPQ(heap); for(int i=K; i<A.Length; i++) pq.InsertAtTop(A[i]); foreach(var i in pq.PQ()) yield return i; }