ds

package
v0.0.0-...-6414846 Latest Latest
Warning

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

Go to latest
Published: Mar 2, 2024 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BinarySearchTree

type BinarySearchTree struct {
	// contains filtered or unexported fields
}

func NewBinarySearchTree

func NewBinarySearchTree() *BinarySearchTree

func (*BinarySearchTree) Add

func (bst *BinarySearchTree) Add(val int)

func (*BinarySearchTree) Traverse

func (bst *BinarySearchTree) Traverse(callback func(val int))

type OrderList

type OrderList struct {
	// contains filtered or unexported fields
}

func NewOrderList

func NewOrderList() *OrderList

func (*OrderList) Add

func (ol *OrderList) Add(val int)

func (*OrderList) KMax

func (ol *OrderList) KMax(k int) (val int, err error)

func (*OrderList) Traverse

func (ol *OrderList) Traverse(lambda func(val int))

Jump to

Keyboard shortcuts

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