Skip to main content

Hashi

Hashiwokakero ("Bridges") puzzle generator, solver, printer, and player for the terminal.

Features

  • Generate random Hashiwokakero puzzles of customizable size and difficulty
  • Play interactively in the terminal
  • Print puzzles and solutions in ASCII

Installation

Clone this repository and install with pip (optional):

pip install .

Usage

You can run the game from the command line:

python -m hashi --width 5 --height 5 --difficulty 40

All arguments are optional. Defaults are:

  • width: 5
  • height: 5
  • difficulty: 40

How to Play

  • Connect islands with bridges so that all islands are connected and the number on each island matches the number of bridges connected to it.
  • Enter moves in the format:
    • - a4 c4 : Add a single bridge between a4 and c4
    • = e7 e3 : Add a double bridge between e7 and e3
    • . a4 c4 : Remove any bridge between a4 and c4
    • q : Quit

Author

Al Sweigart

Release files for hashi 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for hashi 0.1.0
File Size Uploaded
hashi-0.1.0.tar.gz 5.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for hashi 0.1.0
File Interpreter ABI Platform
hashi-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 11.4 kB

Release files / hashi-0.1.0.tar.gz

Download URL hashi-0.1.0.tar.gz
Size 5.5 kB
Tags Source
SHA-256 checksum
How to use checksums
d320b4d8507fd7f0363b2da5079b45ef868c930ef6a78ae0ddc72b3e6d25b5d9
BLAKE2b-256 checksum
How to use checksums
bd0db605b3564c0d9b639c43236a5f13a6393bc23993f34e893817e63ac6ae0b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release files / hashi-0.1.0-py3-none-any.whl

Download URL hashi-0.1.0-py3-none-any.whl
Size 6.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0353908e723fa788f3c2cb75709b8792f5ba90249e376c201d6ce714f1ff1750
BLAKE2b-256 checksum
How to use checksums
04b2087c25c3cb017d5863a13ba75c3cd55bceac3d1a62245e10d0da915f49d0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.7

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page