Documentation ¶
Index ¶
- type MaxHeap
- func (h *MaxHeap) Add(e interface{})
- func (h *MaxHeap) FindMax() interface{}
- func (h *MaxHeap) GetSize() int
- func (h *MaxHeap) IsEmpty() bool
- func (h *MaxHeap) Remove() interface{}
- func (h *MaxHeap) Replace(e interface{}) interface{}
- func (h *MaxHeap) SiftDown(index int)
- func (h *MaxHeap) SiftUp(index int)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MaxHeap ¶
type MaxHeap struct {
// contains filtered or unexported fields
}
最大堆
func Constructor ¶
func GetMaxHeapFromArr ¶
func GetMaxHeapFromArr(arr []interface{}) *MaxHeap
Click to show internal directories.
Click to hide internal directories.