Solve the daily Letterboxed word puzzle from the New York Times.
Project description
Letterboxed Solver
Python module to solve the daily word puzzle from the New York Times.
Installation
python -mpip install letterboxed
Usage
You will need a local dictionary file in order to use this module if you want to specify custom puzzles with '-l'.
$ letterboxed -h
usage: letterboxed [-h] (-n | -l top-rgt-lft-btm) [-d <file>]
NYT Letterboxed Two-Solver
options:
-h, --help show this help message and exit
-n Pull today's puzzle from the NYTimes website.
-l top-rgt-lft-btm Specify the letters you want on the box.
-d <file> Dictionary File
# Puzzle for December 8, 2023
$ letterboxed -d /usr/share/dict/american-english -l CTO-UFM-QZB-INA -d /usr/share/dict/american-english-huge
quiz -> zombification
$ letterboxed -n
Today's puzzle is CTO-UFM-QZB-INA
quiz -> zombification
quoz -> zombification
Example python module usage:
from letterboxed import Letterbox
with open("/usr/share/dict/american-english-small", "r") as fp:
dict = fp.read().split("\n")
lbox = Letterbox((('a', 'e', 'g'), ('h','i','l'), ('c', 'm', 'v'), ('p', 'o', 't')), dict)
for pair in lbox.solve():
print(" -> ".join(pair))
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
letterboxed-0.0.4.tar.gz
(4.1 kB
view hashes)
Built Distribution
Close
Hashes for letterboxed-0.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e9145733a4a963dcd0b1f39b2a7de85093cee7721d10eee31c6926ebc5251b68 |
|
MD5 | 287ca1976256b2e5d7fc0d1b4ad5cb75 |
|
BLAKE2b-256 | ab8a907edd1408dd07cf60ff6b0af4b564a60b7a4fbfeac1328a0ada1f45d9d9 |