package
module
Version:
v0.0.0-...-52d6ee5
Opens a new window with list of versions in this module.
Published: Mar 1, 2022
License: MIT
Opens a new window with license information.
Imports: 1
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
¶
go-algorithms

The library implementing some basic algorithms and data structures.
- algorithms:
- search:
- filtering out the non-unique items in a slice:
- universal
- in a sorted slice only
- via a set (a data structure); i.e., in a slice containing hashable items only
- merging two sorted slices
- sorting:
- data structures:
- set:
- operations:
- checking that a set contains an item
- adding an item
- removing an item
- evaluating union with another set
- evaluating intersection with another set
- evaluating difference between two sets
- multiset:
- operations:
- checking that a set contains an item
- adding an item
- removing an item
- evaluating sum with another set
- evaluating union with another set
- evaluating intersection with another set
- evaluating difference between two sets
Installation
$ go get github.com/irenicaa/go-algorithms
License
The MIT License (MIT)
Copyright © 2022 irenica
Documentation
¶
func UniqueFast(items []interface{}) []interface{}
UniqueFast ...
Items should be hashable.
type Equal interface {
Equal(other interface{}) bool
}
Equal ...
type Less interface {
Less(other interface{}) bool
}
Less ...
Source Files
¶
Directories
¶
Click to show internal directories.
Click to hide internal directories.