heap

package
v1.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 27, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Heap

type Heap[T Interface] heap.Heap[T, int]

func New

func New[T Interface](l int) Heap[T]

func NewFromArray

func NewFromArray[T Interface](arr []T) Heap[T]

func (*Heap[T]) First

func (heap *Heap[T]) First() T

func (*Heap[T]) Fix

func (heap *Heap[T]) Fix(i int)

func (Heap[T]) Init

func (heap Heap[T]) Init()

func (*Heap[T]) Last

func (heap *Heap[T]) Last() T

func (*Heap[T]) Pop

func (heap *Heap[T]) Pop() T

func (*Heap[T]) Push

func (heap *Heap[T]) Push(x T)

func (*Heap[T]) Remove

func (heap *Heap[T]) Remove(i int) T

type Interface

type Interface interface {
	OrderKey() int
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL