from heapq import heapify
from random import sample

def is_minheap(lst):
    return all(lst[i] >= lst[i - 1 >> 1] for i in range(1, len(lst)))

lst = sample(range(10), 10)
print(is_minheap(lst), lst)
heapify(lst)
print(is_minheap(lst), lst)