Add solution for isHeap