This is a Nonogram solver that can solve only single solution puzzles. It can theoreitcally solve any of them, but it's recommended to solve only puzzles with a size less than 27 or even more.
Don't take this project too seriously, it was done only to have fun.
- Clone the repository
- Install the required Python modules (
$ python -m pip install -r requirements.txt
) - (optional) If you want to use the PHONE mode you must have installed ADB in your system, and you have to connect your device with debugging mode enabled. You can find a lot of good guides online on how to do it.
DISCLAIMER: The PHONE mode only works on this app: Nonogram from Easybrain.
Usage syntax:
$ python src/nonogram.py [file|PHONE]
If no arguments are given the solver will ask the user the size of the Nongoram and its rules. If the second argument is a file the solver will read the input from that file. The input must be formatted in the following way:
- The first line will contain, N, the size of the Nonogram
- The next N lines will contain the rules of the rows
- The next N lines will contains the rules of the columns
If the second argument is
PHONE
then the solver will ask the user the size and the rules of the Nonogram, and it will also ask to touch a cell in the top left quarter of the grid and when it solves the Nonogram the solution will be sent to the phone. Obviously you'll have to connect your phone via ADB, if you don't know how to do that there are a lot of good guides online as I said before.
To test the solver there are some test files in the tests folder.