I've been using a quicksort function to sort my stringlists, but as an exercise I wanted to try and code an heapsort function too. Unfortunately it does not wor
def min_heapify(A,k, n): left = 2*k +1 right = 2*k +2 n=int(len(A)) if left < n and A[left] < A[k]: smallest = left else: