somedata

package module
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2025 License: MIT Imports: 1 Imported by: 0

README

somedata

Some data structures realizations in go

Types

Linear
  • Deque - double-ended queue: tested ✅
  • Dict - dictionary based on hash map tables from GO: tested ✅
  • Disjoint Set - djointset: tested ✅
  • Linked list: in process 🚩
Matrix (flat slice realization)
  • 2D matrix: tested ✅
  • 3D matrix: tested ✅
  • Multi dimensional matrix: in process 🚩
Ring buffer
  • Byte ring buffer (impements: io.ReadWriter): tested ✅
  • Ring buffer: tested ✅ (zero allocations in static size types)
Tree
  • BST - searching tree: tested ✅

License

MIT

Documentation

Index

Constants

View Source
const (
	ErrRingBufferInvalidSize sErr = "ring buffer: size must be above 0"
	ErrRingBufferOverflow    sErr = "ring buffer: overflow"
)

=============== Ring buffer errors ===============

View Source
const (
	ErrDequeDuringIter sErr = "deque: modified during iteration"
)
View Source
const (
	ErrNilBstNode sErr = "tree BST: node is nil"
)

=============== Tree BST errors ===============

Variables

This section is empty.

Functions

func ErrDequeCalledNegCount added in v0.5.0

func ErrDequeCalledNegCount(fun string) sErr

func ErrDequeEmptyQueue added in v0.5.0

func ErrDequeEmptyQueue(fun string) sErr

=============== Deque buffer errors ===============

func ErrDequeOutOfRange added in v0.5.0

func ErrDequeOutOfRange(r, l int) sErr

func ErrMatDimCoordMismatch added in v0.5.0

func ErrMatDimCoordMismatch(rank int) sErr

func ErrMatNegativeCoords added in v0.5.0

func ErrMatNegativeCoords(rank int) sErr

func ErrMatOutCoords added in v0.5.0

func ErrMatOutCoords(rank int) sErr

func ErrMatUnequalShapes added in v0.5.0

func ErrMatUnequalShapes(rank int) sErr

=============== Matrix errors ===============

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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