Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/derekparker/trie
Data structure and relevant algorithms for extremely fast prefix/fuzzy string searching.
https://github.com/derekparker/trie
Last synced: about 1 month ago
JSON representation
Data structure and relevant algorithms for extremely fast prefix/fuzzy string searching.
- Host: GitHub
- URL: https://github.com/derekparker/trie
- Owner: derekparker
- License: mit
- Created: 2014-03-06T22:01:49.000Z (about 10 years ago)
- Default Branch: v3
- Last Pushed: 2023-09-29T20:33:42.000Z (8 months ago)
- Last Synced: 2024-01-30T04:06:24.352Z (4 months ago)
- Language: Go
- Homepage:
- Size: 66.4 KB
- Stars: 721
- Watchers: 23
- Forks: 113
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Lists
- awesome-go - trie - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
- awesome-go - trie - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
- awesome-go-cn - trie
- awesome-go-extra - trie - 03-06T22:01:49Z|2022-03-19T00:15:59Z| (Generators / Text Analysis)
- awesome-go - trie - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
- awesome-go - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-go - trie - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
- fucking-awesome-go - :octocat: trie - Trie implementation in Go :star: 123 :fork_and_knife: 15 (Data Structures / Advanced Console UIs)
- awesome-go - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-go-projects - trie - Trie implementation in Go. (Data Structures / Standard CLI)
- awesome-go - trie - | - | - | (Data Structures / Advanced Console UIs)
- awesome-go - trie - Trie implementation in Go (Data Structures / Advanced Console UIs)
- awesome-go-with-framework - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-go-cn - trie
- awesome-go - trie - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
- go-awesome-cn-star - trie
- awesome-go-stars - trie(stars: 723) - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
- awesome-go - trie - Trie implementation in Go (Data Structures / Advanced Console UIs)
- awesome-go - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-go - trie - GO语言实现Trie。 (<span id="数据结构-data-structures">数据结构 Data Structures</span> / <span id="高级控制台用户界面-advanced-console-uis">高级控制台用户界面 Advanced Console UIs</span>)
- awesome-go. - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-go-cn - trie - Go语言实现的Trie树 (数据结构 / 高级控制台界面)
- awesome-go-with-stars - trie - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
- awesome-go - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- repo-1316-awesome-go-cn - trie
- repo-1211-awesome-go-cn - trie
- awesome-Char - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-reader - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-go - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- Go-awesome - trie - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
- awesome-go-cn - trie
- awesome-go-cn - trie
- awesome-go - trie - Trie implementation in Go (Data Structures / Advanced Console UIs)
- awesome-go-handwritten - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-go - trie - Go語言實現的Trie樹 (數據結構 / 高級控制台界面)
- awesome-go - trie - Data structure and relevant algorithms for extremely fast prefix/fuzzy string searching. - ★ 325 (Data Structures)
- awesome-go - trie - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
- awesome-go2 - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-go - trie - Trie implementation in Go (Data Structures / Advanced Console UIs)
- awesome-go - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-go - trie - Trie implementation in Go. - :arrow_down:4 - :star:142 (Data Structures / Advanced Console UIs)
- awesome-go - trie - Trie implementation in Go. (Data Structures / Advanced Console UIs)
- awesome-go-zh - trie
- awesome-go-cn - trie
- awesome-stars - derekparker/trie - `★731` Data structure and relevant algorithms for extremely fast prefix/fuzzy string searching. (Go)
- awesome-go - trie - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
- awesome-go - trie - Trie implementation in Go. (Data Structures and Algorithms / Text Analysis)
README
[![GoDoc](https://godoc.org/github.com/derekparker/trie?status.svg)](https://godoc.org/github.com/derekparker/trie)
# Trie
Data structure and relevant algorithms for extremely fast prefix/fuzzy string searching.## Usage
Create a Trie with:
```Go
t := trie.New()
```Add Keys with:
```Go
// Add can take in meta information which can be stored with the key.
// i.e. you could store any information you would like to associate with
// this particular key.
t.Add("foobar", 1)
```Find a key with:
```Go
node, ok := t.Find("foobar")
meta := node.Meta()
// use meta with meta.(type)
```Remove Keys with:
```Go
t.Remove("foobar")
```Prefix search with:
```Go
t.PrefixSearch("foo")
```Fast test for valid prefix:
```Go
t.HasKeysWithPrefix("foo")
```Fuzzy search with:
```Go
t.FuzzySearch("fb")
```## Contributing
Fork this repo and run tests with:go test
Create a feature branch, write your tests and code and submit a pull request.
## License
MIT