albrow / stringset

A simple and space-effecient Go implementation of a set of strings.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

stringset

Version Circle CI GoDoc

A simple and space-effecient Go implementation of a set of strings.

Basic Usage

s := stringset.New()
s.Add("foo")
s.Add("bar", "baz")
fmt.Println(s)
// Output:
// [bar foo baz]

fmt.Println(s.Contains("foo"))
// Output:
// true

s.Remove("bar")
fmt.Println(s)
// Output:
// [foo]

About

A simple and space-effecient Go implementation of a set of strings.


Languages

Language:Go 100.0%