util

package
v0.0.0-...-64841bc Latest Latest
Warning

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

Go to latest
Published: Dec 26, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CopyMap

func CopyMap(original [][]rune) [][]rune

func GetSingleKey

func GetSingleKey[K comparable, V any](m map[K]V) K

func MapsEqual

func MapsEqual(a, b [][]rune) bool

func NewCounts

func NewCounts(s string) map[rune]int

func NewIntSet

func NewIntSet(slice []int) map[int]bool

TODO: replace with generic?

func NewRange

func NewRange(start, end int) []int

func NewRuneSet

func NewRuneSet(s string) map[rune]bool

func ParseSlice

func ParseSlice(s string, sep string) []int

func PrintMap

func PrintMap(m [][]rune)

func ReadLines

func ReadLines(filename string) []string

func ReadMap

func ReadMap(filename string) [][]rune

func SlicesEqual

func SlicesEqual(a, b []int) bool

func Sum

func Sum[V constraints.Integer | constraints.Float](xs []V) V

Types

This section is empty.

Jump to

Keyboard shortcuts

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