Implement the basic interface of binary heap.