Python wrapper of cGADDAG
Project description
GADDAG is a Python wrapper around cGADDAG.
A GADDAG data structure provides rapid word lookups for prefixes, suffixes and substrings, making it ideal for use in applications such as move generation in word games such as Scrabble.
Basic usage:
>>> import gaddag >>> words = ["foo", "bar", "foobar", "baz"] >>> gdg = gaddag.GADDAG(words) >>> "foo" in gdg True >>> "bor" in gdg False >>> gdg.contains("ba") ['bar', 'foobar', 'baz']
GADDAG currently only supports the ASCII alphabet.
Installation
From PyPI:
pip install gaddag
Documentation
Documentaion is available at http://gaddag.readthedocs.io.
License
Licensed under the MIT License, see LICENSE.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
GADDAG-0.4.tar.gz
(247.7 kB
view hashes)
Built Distribution
Close
Hashes for GADDAG-0.4-cp37-cp37m-macosx_10_13_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6c41bd968f7ea31757772099f1478cb1d9d6b0a428b3a291f48aca07a444a8fd |
|
MD5 | 7d1923afb99264e552aea778044f4d20 |
|
BLAKE2b-256 | f89c7a74bac28fb213cadc0256a20438c9d4694ec8685ae13d905b8fc2febf90 |