multi-puzzle-solver 0.9.20__py3-none-any.whl → 0.9.24__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of multi-puzzle-solver might be problematic. Click here for more details.
- {multi_puzzle_solver-0.9.20.dist-info → multi_puzzle_solver-0.9.24.dist-info}/METADATA +341 -3
- {multi_puzzle_solver-0.9.20.dist-info → multi_puzzle_solver-0.9.24.dist-info}/RECORD +12 -8
- puzzle_solver/__init__.py +4 -1
- puzzle_solver/core/utils.py +135 -0
- puzzle_solver/puzzles/binairo/binairo.py +98 -0
- puzzle_solver/puzzles/rectangles/rectangles.py +130 -0
- puzzle_solver/puzzles/slitherlink/slitherlink.py +4 -128
- puzzle_solver/puzzles/sudoku/sudoku.py +136 -23
- puzzle_solver/puzzles/yin_yang/parse_map/parse_map.py +172 -0
- puzzle_solver/puzzles/yin_yang/yin_yang.py +110 -0
- {multi_puzzle_solver-0.9.20.dist-info → multi_puzzle_solver-0.9.24.dist-info}/WHEEL +0 -0
- {multi_puzzle_solver-0.9.20.dist-info → multi_puzzle_solver-0.9.24.dist-info}/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: multi-puzzle-solver
|
|
3
|
-
Version: 0.9.
|
|
3
|
+
Version: 0.9.24
|
|
4
4
|
Summary: Efficient solvers for numerous popular and esoteric logic puzzles using CP-SAT
|
|
5
5
|
Author: Ar-Kareem
|
|
6
6
|
Project-URL: Homepage, https://github.com/Ar-Kareem/puzzle_solver
|
|
@@ -309,6 +309,23 @@ These are all the puzzles that are implemented in this repo. <br> Click on any o
|
|
|
309
309
|
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/slitherlink_solved.png" alt="Slitherlink" width="140">
|
|
310
310
|
</a>
|
|
311
311
|
</td>
|
|
312
|
+
<td align="center">
|
|
313
|
+
<a href="#yin-yang-puzzle-type-40"><b>Yin-Yang</b><br><br>
|
|
314
|
+
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/yin_yang_solved.png" alt="Yin-Yang" width="140">
|
|
315
|
+
</a>
|
|
316
|
+
</td>
|
|
317
|
+
</tr>
|
|
318
|
+
<tr>
|
|
319
|
+
<td align="center">
|
|
320
|
+
<a href="#binairo-puzzle-type-41"><b>Binairo</b><br><br>
|
|
321
|
+
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/binairo_solved.png" alt="Binairo" width="140">
|
|
322
|
+
</a>
|
|
323
|
+
</td>
|
|
324
|
+
<td align="center">
|
|
325
|
+
<a href="#rectangles-puzzle-type-42"><b>Rectangles</b><br><br>
|
|
326
|
+
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/rectangles_solved.png" alt="Rectangles" width="140">
|
|
327
|
+
</a>
|
|
328
|
+
</td>
|
|
312
329
|
</tr>
|
|
313
330
|
</table>
|
|
314
331
|
|
|
@@ -363,6 +380,9 @@ These are all the puzzles that are implemented in this repo. <br> Click on any o
|
|
|
363
380
|
- [Unequal (Puzzle Type #37)](#unequal-puzzle-type-37)
|
|
364
381
|
- [Norinori (Puzzle Type #38)](#norinori-puzzle-type-38)
|
|
365
382
|
- [Slitherlink (Puzzle Type #39)](#slitherlink-puzzle-type-39)
|
|
383
|
+
- [Yin-Yang (Puzzle Type #40)](#yin-yang-puzzle-type-40)
|
|
384
|
+
- [Binairo (Puzzle Type #41)](#binairo-puzzle-type-41)
|
|
385
|
+
- [Rectangles (Puzzle Type #42)](#rectangles-puzzle-type-42)
|
|
366
386
|
- [Why SAT / CP-SAT?](#why-sat--cp-sat)
|
|
367
387
|
- [Testing](#testing)
|
|
368
388
|
- [Contributing](#contributing)
|
|
@@ -488,6 +508,13 @@ You are given some of the numbers as clues; your aim is to place the rest of the
|
|
|
488
508
|
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/sudoku_unsolved.png" alt="Sudoku unsolved" width="500">
|
|
489
509
|
|
|
490
510
|
Code to utilize this package and solve the puzzle:
|
|
511
|
+
|
|
512
|
+
Note:
|
|
513
|
+
|
|
514
|
+
- The solver also supports solving the ["Sandwich" sudoku variant](https://dkmgames.com/SandwichSudoku/) through the optional parameter ``sandwich={'side': [...], 'bottom': [...] }``。
|
|
515
|
+
|
|
516
|
+
- The solver also supports solving the ["Sudoku-X" variant](https://www.sudopedia.org/wiki/Sudoku-X) through the optional parameter ``unique_diagonal=True``。
|
|
517
|
+
|
|
491
518
|
```python
|
|
492
519
|
import numpy as np
|
|
493
520
|
from puzzle_solver import sudoku_solver as solver
|
|
@@ -2220,6 +2247,7 @@ The numbers outside the grid show the number of filled cells horizontally and ve
|
|
|
2220
2247
|
Code to utilize this package and solve the puzzle:
|
|
2221
2248
|
|
|
2222
2249
|
```python
|
|
2250
|
+
import numpy as np
|
|
2223
2251
|
from puzzle_solver import thermometers_solver as solver
|
|
2224
2252
|
board = np.array([
|
|
2225
2253
|
['R', 'R', 'D', 'R', 'D', 'R', 'X', 'D', 'L', 'X', 'L', 'L', 'L', 'L', 'L'],
|
|
@@ -2299,6 +2327,7 @@ The numbers outside the grid show the number of filled cells horizontally and ve
|
|
|
2299
2327
|
Code to utilize this package and solve the puzzle:
|
|
2300
2328
|
|
|
2301
2329
|
```python
|
|
2330
|
+
import numpy as np
|
|
2302
2331
|
from puzzle_solver import aquarium_solver as solver
|
|
2303
2332
|
board = np.array([
|
|
2304
2333
|
['01', '01', '01', '01', '02', '02', '02', '03', '03', '03', '03', '04', '05', '05', '05'],
|
|
@@ -2376,6 +2405,7 @@ Time taken: 0.02 seconds
|
|
|
2376
2405
|
Code to utilize this package and solve the puzzle:
|
|
2377
2406
|
|
|
2378
2407
|
```python
|
|
2408
|
+
import numpy as np
|
|
2379
2409
|
from puzzle_solver import stitches_solver as solver
|
|
2380
2410
|
board = np.array([
|
|
2381
2411
|
["00", "00", "00", "00", "00", "01", "01", "01", "01", "01", "01", "01", "01", "02", "02"],
|
|
@@ -2456,6 +2486,7 @@ Time taken: 0.01 seconds
|
|
|
2456
2486
|
Code to utilize this package and solve the puzzle:
|
|
2457
2487
|
|
|
2458
2488
|
```python
|
|
2489
|
+
import numpy as np
|
|
2459
2490
|
from puzzle_solver import battleships_solver as solver
|
|
2460
2491
|
board = np.array([
|
|
2461
2492
|
[' ', ' ', ' ', ' ', ' ', 'S', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' '],
|
|
@@ -2538,6 +2569,7 @@ The goal is to make some of the cells black in such a way that:
|
|
|
2538
2569
|
Code to utilize this package and solve the puzzle:
|
|
2539
2570
|
|
|
2540
2571
|
```python
|
|
2572
|
+
import numpy as np
|
|
2541
2573
|
from puzzle_solver import kakurasu_solver as solver
|
|
2542
2574
|
side = np.array([27, 6, 1, 12, 37, 37, 11, 4, 29, 23, 66, 55])
|
|
2543
2575
|
bottom = np.array([22, 1, 25, 36, 10, 22, 25, 35, 32, 28, 45, 45])
|
|
@@ -2598,6 +2630,7 @@ Code to utilize this package and solve the puzzle:
|
|
|
2598
2630
|
Note that as usual the board is an id of the shape (id is meaningless, just used to identify one shape), and the `star_count` parameter depenends on the puzzle type.
|
|
2599
2631
|
|
|
2600
2632
|
```python
|
|
2633
|
+
import numpy as np
|
|
2601
2634
|
from puzzle_solver import star_battle_solver as solver
|
|
2602
2635
|
board = np.array([
|
|
2603
2636
|
['00', '00', '00', '00', '00', '01', '01', '01', '01', '01', '01', '01', '01', '01', '02', '02', '02', '03', '03', '03', '03', '03', '03', '03', '03'],
|
|
@@ -2697,7 +2730,8 @@ Code to utilize this package and solve the puzzle:
|
|
|
2697
2730
|
The `star_count` parameter depenends on the puzzle type.
|
|
2698
2731
|
|
|
2699
2732
|
```python
|
|
2700
|
-
|
|
2733
|
+
import numpy as np
|
|
2734
|
+
from puzzle_solver import star_battle_shapeless as solver
|
|
2701
2735
|
board = np.array([
|
|
2702
2736
|
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' '],
|
|
2703
2737
|
['B', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' '],
|
|
@@ -2710,7 +2744,7 @@ board = np.array([
|
|
|
2710
2744
|
['B', 'B', ' ', ' ', ' ', ' ', 'B', 'B', 'B', ' '],
|
|
2711
2745
|
['B', ' ', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' '],
|
|
2712
2746
|
])
|
|
2713
|
-
binst =
|
|
2747
|
+
binst = solver.Board(board=board, star_count=2)
|
|
2714
2748
|
solutions = binst.solve_and_print()
|
|
2715
2749
|
```
|
|
2716
2750
|
|
|
@@ -2767,6 +2801,8 @@ Note: The solver is capable of solving variations where the puzzle pieces the ma
|
|
|
2767
2801
|
Code to utilize this package and solve the puzzle:
|
|
2768
2802
|
|
|
2769
2803
|
```python
|
|
2804
|
+
import numpy as np
|
|
2805
|
+
from puzzle_solver import lits_solver as solver
|
|
2770
2806
|
board = np.array([
|
|
2771
2807
|
['00', '00', '00', '01', '01', '02', '02', '02', '03', '03', '03', '04', '04', '05', '06', '07', '07', '08', '08', '09'],
|
|
2772
2808
|
['00', '00', '00', '00', '01', '02', '03', '03', '03', '10', '04', '04', '05', '05', '06', '07', '08', '08', '09', '09'],
|
|
@@ -2963,6 +2999,7 @@ Code to utilize this package and solve the puzzle:
|
|
|
2963
2999
|
Note: The number are arbitrary and simply number each galaxy as an integer.
|
|
2964
3000
|
|
|
2965
3001
|
```python
|
|
3002
|
+
import numpy as np
|
|
2966
3003
|
from puzzle_solver import galaxies_solver as solver
|
|
2967
3004
|
galaxies = np.array([
|
|
2968
3005
|
[' ', ' ', '00', ' ', ' ', '01', '01', '02', '02', '03', '03', ' ', '04', '04', ' '],
|
|
@@ -3047,6 +3084,7 @@ Code to utilize this package and solve the puzzle:
|
|
|
3047
3084
|
Note: For an NxM board you need an (N+1)x(M+1) array because the puzzle is to solve for the cells while the input is the values at the corners (there's always one more corner than cells in each dimension).
|
|
3048
3085
|
|
|
3049
3086
|
```python
|
|
3087
|
+
import numpy as np
|
|
3050
3088
|
from puzzle_solver import slant_solver as solver
|
|
3051
3089
|
board = np.array([
|
|
3052
3090
|
[' ', ' ', '1', ' ', '1', ' ', '1', ' ', '1', ' ', ' ', ' ', ' '],
|
|
@@ -3131,6 +3169,7 @@ Code to utilize this package and solve the puzzle:
|
|
|
3131
3169
|
Note: For an NxM board you need an (2N-1)x(2M-1) array because the puzzle involves input in between the cells. Each numbered cell has neighbors horizontally to represent ">", "<", and "|" (where "|" represents adjacency) and vertically to represent "∧", "∨" and "-" (where "-" represents adjacency). The "X" in the input are unused corners that shouldnt contain anything (just a corner). The numbers should never appear orthogonal to an "X", only diagonally to it. vice-versa for the comparison operators.
|
|
3132
3170
|
|
|
3133
3171
|
```python
|
|
3172
|
+
import numpy as np
|
|
3134
3173
|
from puzzle_solver import unequal_solver as solver
|
|
3135
3174
|
board = np.array([
|
|
3136
3175
|
[' ', ' ', ' ', ' ', '9', ' ', '1', ' ', '7', '>', ' ', '>', ' ', ' ', ' ', ' ', ' ', '>', ' '],
|
|
@@ -3210,6 +3249,7 @@ You have to shade some of the cells in such a way that:
|
|
|
3210
3249
|
Code to utilize this package and solve the puzzle:
|
|
3211
3250
|
|
|
3212
3251
|
```python
|
|
3252
|
+
import numpy as np
|
|
3213
3253
|
from puzzle_solver import norinori_solver as solver
|
|
3214
3254
|
board = np.array([
|
|
3215
3255
|
['00', '01', '01', '01', '01', '02', '03', '03', '04', '04', '04', '05', '05', '05', '06', '07', '08', '08', '09', '09'],
|
|
@@ -3299,6 +3339,7 @@ A line forming a single loop without crossings or branches means that every corn
|
|
|
3299
3339
|
Code to utilize this package and solve the puzzle:
|
|
3300
3340
|
|
|
3301
3341
|
```python
|
|
3342
|
+
import numpy as np
|
|
3302
3343
|
from puzzle_solver import slitherlink_solver as solver
|
|
3303
3344
|
board = np.array([
|
|
3304
3345
|
['3', ' ', ' ', '2', ' ', ' ', ' ', ' ', ' ', '3', ' ', ' ', ' ', ' ', ' ', '3', ' ', ' ', '1', ' '],
|
|
@@ -3385,6 +3426,300 @@ Applying the solution to the puzzle visually:
|
|
|
3385
3426
|
|
|
3386
3427
|
---
|
|
3387
3428
|
|
|
3429
|
+
## Yin-Yang (Puzzle Type #40)
|
|
3430
|
+
|
|
3431
|
+
* [**Play online**](https://www.puzzle-yin-yang.com)
|
|
3432
|
+
|
|
3433
|
+
* [**Solver Code**][40]
|
|
3434
|
+
|
|
3435
|
+
<details>
|
|
3436
|
+
<summary><strong>Rules</strong></summary>
|
|
3437
|
+
|
|
3438
|
+
Yin-Yang is played on a rectangular grid with no standard size. Some cells start out filled with black or white. The rest of the cells are empty. The goal is to color all cells in such a way that:
|
|
3439
|
+
1. All black cells should be connected orthogonally in a single group.
|
|
3440
|
+
2. All white cells should be connected orthogonally in a single group.
|
|
3441
|
+
3. 2x2 areas of the same color are not allowed.
|
|
3442
|
+
|
|
3443
|
+
</details>
|
|
3444
|
+
|
|
3445
|
+
**Unsolved puzzle**
|
|
3446
|
+
|
|
3447
|
+
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/yin_yang_unsolved.png" alt="Yin-Yang unsolved" width="500">
|
|
3448
|
+
|
|
3449
|
+
Code to utilize this package and solve the puzzle:
|
|
3450
|
+
|
|
3451
|
+
```python
|
|
3452
|
+
import numpy as np
|
|
3453
|
+
from puzzle_solver import yin_yang_solver as solver
|
|
3454
|
+
board = np.array([
|
|
3455
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' '],
|
|
3456
|
+
[' ', ' ', ' ', ' ', ' ', 'W', ' ', ' ', ' ', 'B', ' ', ' ', 'W', ' ', 'W', ' ', ' ', 'W', ' ', ' '],
|
|
3457
|
+
[' ', ' ', 'B', ' ', 'B', ' ', 'W', ' ', ' ', 'W', 'B', ' ', ' ', ' ', ' ', 'W', ' ', 'W', ' ', ' '],
|
|
3458
|
+
[' ', ' ', ' ', ' ', ' ', 'W', ' ', 'W', ' ', 'B', ' ', ' ', ' ', ' ', 'W', ' ', ' ', 'W', ' ', ' '],
|
|
3459
|
+
[' ', 'W', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'W', 'W', ' ', ' ', ' ', ' ', ' ', ' ', 'W', ' ', ' '],
|
|
3460
|
+
[' ', ' ', ' ', ' ', 'W', ' ', ' ', ' ', 'W', 'B', ' ', ' ', ' ', ' ', ' ', 'W', ' ', 'W', ' ', ' '],
|
|
3461
|
+
[' ', ' ', ' ', ' ', ' ', 'W', ' ', ' ', ' ', ' ', 'B', ' ', 'B', ' ', 'B', 'W', ' ', 'W', ' ', ' '],
|
|
3462
|
+
[' ', ' ', 'B', 'W', 'W', ' ', 'W', ' ', ' ', ' ', 'B', ' ', 'B', ' ', 'B', ' ', ' ', ' ', ' ', ' '],
|
|
3463
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'B', ' ', 'B', ' ', 'B', ' ', 'B', ' ', 'B', ' ', 'B', ' '],
|
|
3464
|
+
[' ', 'W', ' ', 'W', ' ', ' ', 'W', ' ', ' ', ' ', 'B', ' ', 'B', ' ', 'B', ' ', 'B', ' ', 'B', ' '],
|
|
3465
|
+
[' ', ' ', ' ', ' ', 'W', 'B', ' ', ' ', ' ', 'B', ' ', ' ', 'B', ' ', 'B', ' ', 'B', ' ', 'B', ' '],
|
|
3466
|
+
[' ', ' ', 'B', ' ', ' ', ' ', 'B', 'B', ' ', 'W', 'B', ' ', 'B', ' ', 'B', ' ', ' ', 'B', ' ', ' '],
|
|
3467
|
+
[' ', 'W', 'W', 'W', ' ', 'B', ' ', 'W', ' ', ' ', 'B', ' ', 'B', ' ', 'B', ' ', ' ', ' ', 'B', ' '],
|
|
3468
|
+
[' ', ' ', ' ', ' ', ' ', ' ', 'W', ' ', ' ', 'B', ' ', 'B', ' ', ' ', 'B', ' ', 'B', ' ', 'B', ' '],
|
|
3469
|
+
[' ', 'W', ' ', 'B', 'W', 'B', ' ', 'W', ' ', ' ', ' ', ' ', 'B', 'B', ' ', ' ', 'B', ' ', 'B', ' '],
|
|
3470
|
+
[' ', ' ', ' ', ' ', 'W', ' ', ' ', 'B', 'B', 'B', 'B', 'B', ' ', ' ', ' ', 'B', ' ', ' ', 'B', ' '],
|
|
3471
|
+
[' ', 'W', ' ', ' ', ' ', 'W', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'B', ' ', 'B', ' '],
|
|
3472
|
+
['W', ' ', ' ', 'W', ' ', ' ', 'B', ' ', ' ', 'B', 'B', 'B', 'B', 'B', ' ', ' ', 'B', ' ', 'B', ' '],
|
|
3473
|
+
[' ', 'W', 'W', ' ', 'W', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' ', ' ', 'B', ' ', 'B', ' ', 'B', ' '],
|
|
3474
|
+
['B', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'B', 'W']
|
|
3475
|
+
])
|
|
3476
|
+
binst = solver.Board(board=board)
|
|
3477
|
+
solutions = binst.solve_and_print()
|
|
3478
|
+
```
|
|
3479
|
+
|
|
3480
|
+
**Script Output**
|
|
3481
|
+
|
|
3482
|
+
```python
|
|
3483
|
+
Solution found
|
|
3484
|
+
[
|
|
3485
|
+
[ 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W' ],
|
|
3486
|
+
[ 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'B', 'B', 'B', 'B', 'B', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'W' ],
|
|
3487
|
+
[ 'W', 'W', 'B', 'W', 'B', 'W', 'W', 'W', 'W', 'W', 'B', 'W', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'W' ],
|
|
3488
|
+
[ 'W', 'B', 'B', 'B', 'B', 'W', 'B', 'W', 'B', 'B', 'B', 'B', 'B', 'B', 'W', 'B', 'B', 'W', 'B', 'W' ],
|
|
3489
|
+
[ 'W', 'W', 'W', 'B', 'W', 'W', 'B', 'W', 'W', 'W', 'W', 'W', 'B', 'W', 'W', 'W', 'B', 'W', 'B', 'W' ],
|
|
3490
|
+
[ 'W', 'B', 'W', 'B', 'W', 'B', 'B', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3491
|
+
[ 'W', 'B', 'B', 'B', 'W', 'W', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3492
|
+
[ 'W', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3493
|
+
[ 'W', 'B', 'B', 'B', 'B', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3494
|
+
[ 'W', 'W', 'W', 'W', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3495
|
+
[ 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'W', 'B', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3496
|
+
[ 'W', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'B', 'B', 'W' ],
|
|
3497
|
+
[ 'W', 'W', 'W', 'W', 'W', 'B', 'W', 'W', 'W', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'W', 'W', 'B', 'W' ],
|
|
3498
|
+
[ 'W', 'B', 'B', 'B', 'B', 'B', 'W', 'B', 'B', 'B', 'B', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3499
|
+
[ 'W', 'W', 'W', 'B', 'W', 'B', 'W', 'W', 'W', 'W', 'W', 'W', 'B', 'B', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3500
|
+
[ 'W', 'B', 'B', 'B', 'W', 'B', 'W', 'B', 'B', 'B', 'B', 'B', 'B', 'W', 'B', 'B', 'B', 'W', 'B', 'W' ],
|
|
3501
|
+
[ 'W', 'W', 'B', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'B', 'W', 'B', 'W' ],
|
|
3502
|
+
[ 'W', 'B', 'B', 'W', 'B', 'B', 'B', 'B', 'W', 'B', 'B', 'B', 'B', 'B', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3503
|
+
[ 'W', 'W', 'W', 'W', 'W', 'W', 'W', 'B', 'W', 'W', 'W', 'W', 'W', 'W', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3504
|
+
[ 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'B', 'W' ],
|
|
3505
|
+
]
|
|
3506
|
+
Solutions found: 1
|
|
3507
|
+
status: OPTIMAL
|
|
3508
|
+
Time taken: 3.10 seconds
|
|
3509
|
+
```
|
|
3510
|
+
|
|
3511
|
+
**Solved puzzle**
|
|
3512
|
+
|
|
3513
|
+
Applying the solution to the puzzle visually:
|
|
3514
|
+
|
|
3515
|
+
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/yin_yang_solved.png" alt="Yin-Yang solved" width="500">
|
|
3516
|
+
|
|
3517
|
+
---
|
|
3518
|
+
|
|
3519
|
+
## Binairo (Puzzle Type #41)
|
|
3520
|
+
|
|
3521
|
+
* [**Play online**](https://www.puzzle-binairo.com)
|
|
3522
|
+
|
|
3523
|
+
* [**Solver Code**][41]
|
|
3524
|
+
|
|
3525
|
+
<details>
|
|
3526
|
+
<summary><strong>Rules</strong></summary>
|
|
3527
|
+
|
|
3528
|
+
Binairo is played on a rectangular grid with no standard size. Some cells start out filled with black or white circles. The rest of the cells are empty. The goal is to place circles in all cells in such a way that:
|
|
3529
|
+
|
|
3530
|
+
1. Each row and each column must contain an equal number of white and black circles.
|
|
3531
|
+
2. More than two circles of the same color can't be adjacent.
|
|
3532
|
+
3. Each row and column is unique.
|
|
3533
|
+
|
|
3534
|
+
</details>
|
|
3535
|
+
|
|
3536
|
+
**Unsolved puzzle**
|
|
3537
|
+
|
|
3538
|
+
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/binairo_unsolved.png" alt="Binairo unsolved" width="500">
|
|
3539
|
+
|
|
3540
|
+
Code to utilize this package and solve the puzzle:
|
|
3541
|
+
|
|
3542
|
+
```python
|
|
3543
|
+
import numpy as np
|
|
3544
|
+
from puzzle_solver import binairo_solver as solver
|
|
3545
|
+
board = np.array([
|
|
3546
|
+
[' ', ' ', ' ', ' ', 'W', ' ', ' ', ' ', 'W', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'B', ' ', ' ', 'W'],
|
|
3547
|
+
[' ', 'W', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' ', ' ', 'W', ' ', ' ', 'B', ' ', ' ', ' ', 'B', ' '],
|
|
3548
|
+
[' ', 'W', ' ', ' ', ' ', 'W', ' ', 'W', 'W', ' ', ' ', ' ', 'B', ' ', ' ', 'W', ' ', ' ', ' ', ' '],
|
|
3549
|
+
['B', ' ', ' ', 'W', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' ', ' ', ' '],
|
|
3550
|
+
['B', ' ', ' ', ' ', 'W', ' ', ' ', ' ', ' ', 'B', ' ', 'W', ' ', ' ', ' ', 'B', ' ', ' ', ' ', 'W'],
|
|
3551
|
+
[' ', ' ', 'W', ' ', ' ', 'W', ' ', ' ', ' ', ' ', 'W', ' ', ' ', ' ', ' ', ' ', ' ', 'W', ' ', ' '],
|
|
3552
|
+
['W', ' ', ' ', ' ', ' ', ' ', 'B', ' ', ' ', 'B', ' ', ' ', 'B', 'B', ' ', ' ', 'W', ' ', 'B', ' '],
|
|
3553
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' ', 'W', ' ', ' ', ' '],
|
|
3554
|
+
[' ', ' ', ' ', ' ', 'W', ' ', 'B', ' ', 'W', ' ', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' ', ' ', ' '],
|
|
3555
|
+
[' ', 'W', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'W', ' ', ' ', ' ', 'W', 'W', ' ', ' ', ' '],
|
|
3556
|
+
[' ', ' ', 'B', ' ', ' ', ' ', 'B', ' ', 'B', ' ', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' ', ' ', ' '],
|
|
3557
|
+
[' ', 'W', 'B', ' ', 'W', ' ', 'B', ' ', ' ', ' ', ' ', ' ', 'W', 'W', ' ', 'B', ' ', ' ', 'B', ' '],
|
|
3558
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'B', ' ', ' ', ' ', 'B', 'B'],
|
|
3559
|
+
[' ', 'B', ' ', ' ', ' ', ' ', 'W', ' ', 'W', 'W', ' ', ' ', 'W', ' ', ' ', ' ', 'W', ' ', ' ', ' '],
|
|
3560
|
+
[' ', ' ', 'W', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'W', 'W', ' ', ' ', 'W', 'W', ' '],
|
|
3561
|
+
[' ', 'B', ' ', 'B', 'W', ' ', ' ', ' ', ' ', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' '],
|
|
3562
|
+
[' ', 'B', ' ', ' ', ' ', 'W', ' ', ' ', ' ', 'W', ' ', ' ', 'B', ' ', 'B', ' ', ' ', ' ', ' ', ' '],
|
|
3563
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' ', ' ', 'W', ' ', ' ', ' ', 'W'],
|
|
3564
|
+
[' ', ' ', ' ', 'B', 'B', ' ', ' ', 'W', ' ', 'W', ' ', ' ', ' ', ' ', ' ', ' ', ' ', 'B', ' ', ' '],
|
|
3565
|
+
['B', ' ', 'B', 'B', ' ', ' ', ' ', ' ', ' ', 'W', ' ', 'B', ' ', ' ', 'B', ' ', ' ', ' ', ' ', ' ']
|
|
3566
|
+
])
|
|
3567
|
+
binst = solver.Board(board=board)
|
|
3568
|
+
solutions = binst.solve_and_print()
|
|
3569
|
+
```
|
|
3570
|
+
|
|
3571
|
+
**Script Output**
|
|
3572
|
+
|
|
3573
|
+
```python
|
|
3574
|
+
Solution found
|
|
3575
|
+
[
|
|
3576
|
+
[ 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'W' ],
|
|
3577
|
+
[ 'W', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'W', 'B', 'B', 'W', 'W', 'B', 'B', 'W' ],
|
|
3578
|
+
[ 'W', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'B', 'W', 'B' ],
|
|
3579
|
+
[ 'B', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'W', 'B', 'B' ],
|
|
3580
|
+
[ 'B', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'B', 'B', 'W' ],
|
|
3581
|
+
[ 'W', 'B', 'W', 'B', 'B', 'W', 'W', 'B', 'B', 'W', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'W', 'B' ],
|
|
3582
|
+
[ 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'W', 'B', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'B', 'W' ],
|
|
3583
|
+
[ 'B', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'W', 'B', 'W', 'B' ],
|
|
3584
|
+
[ 'W', 'B', 'W', 'B', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'B', 'B', 'W', 'W', 'B', 'B', 'W', 'B', 'W' ],
|
|
3585
|
+
[ 'B', 'W', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'B', 'B', 'W', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'B' ],
|
|
3586
|
+
[ 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'B', 'W', 'W', 'B', 'B', 'W', 'W' ],
|
|
3587
|
+
[ 'B', 'W', 'B', 'W', 'W', 'B', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'W', 'B', 'B', 'W', 'W', 'B', 'W' ],
|
|
3588
|
+
[ 'B', 'W', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'B' ],
|
|
3589
|
+
[ 'W', 'B', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'W' ],
|
|
3590
|
+
[ 'B', 'W', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'W', 'B', 'B', 'W', 'W', 'B' ],
|
|
3591
|
+
[ 'W', 'B', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'W' ],
|
|
3592
|
+
[ 'W', 'B', 'B', 'W', 'B', 'W', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'B' ],
|
|
3593
|
+
[ 'B', 'W', 'B', 'W', 'W', 'B', 'B', 'W', 'B', 'B', 'W', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'B', 'W' ],
|
|
3594
|
+
[ 'W', 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B', 'W', 'B' ],
|
|
3595
|
+
[ 'B', 'W', 'B', 'B', 'W', 'B', 'W', 'B', 'W', 'W', 'B', 'B', 'W', 'W', 'B', 'W', 'B', 'W', 'W', 'B' ],
|
|
3596
|
+
]
|
|
3597
|
+
Solutions found: 1
|
|
3598
|
+
status: OPTIMAL
|
|
3599
|
+
Time taken: 0.03 seconds
|
|
3600
|
+
```
|
|
3601
|
+
|
|
3602
|
+
**Solved puzzle**
|
|
3603
|
+
|
|
3604
|
+
Applying the solution to the puzzle visually:
|
|
3605
|
+
|
|
3606
|
+
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/binairo_solved.png" alt="Binairo solved" width="500">
|
|
3607
|
+
|
|
3608
|
+
---
|
|
3609
|
+
|
|
3610
|
+
## Rectangles (Puzzle Type #42)
|
|
3611
|
+
|
|
3612
|
+
Also called "Shikaku".
|
|
3613
|
+
|
|
3614
|
+
* [**Play online**](https://www.chiark.greenend.org.uk/~sgtatham/puzzles/js/rect.html)
|
|
3615
|
+
|
|
3616
|
+
* [**Instructions**](https://www.chiark.greenend.org.uk/~sgtatham/puzzles/doc/rect.html#rect)
|
|
3617
|
+
|
|
3618
|
+
* [**Solver Code**][42]
|
|
3619
|
+
|
|
3620
|
+
<details>
|
|
3621
|
+
<summary><strong>Rules</strong></summary>
|
|
3622
|
+
|
|
3623
|
+
You have a grid of squares, with numbers written in some (but not all) of the squares. Your task is to subdivide the grid into rectangles of various sizes, such that both:
|
|
3624
|
+
|
|
3625
|
+
- (a) every rectangle contains exactly one numbered square
|
|
3626
|
+
- (b) the area of each rectangle is equal to the number written in its numbered square.
|
|
3627
|
+
|
|
3628
|
+
|
|
3629
|
+
</details>
|
|
3630
|
+
|
|
3631
|
+
**Unsolved puzzle**
|
|
3632
|
+
|
|
3633
|
+
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/rectangles_unsolved.png" alt="Rectangles unsolved" width="500">
|
|
3634
|
+
|
|
3635
|
+
Code to utilize this package and solve the puzzle:
|
|
3636
|
+
|
|
3637
|
+
```python
|
|
3638
|
+
import numpy as np
|
|
3639
|
+
from puzzle_solver import rectangles_solver as solver
|
|
3640
|
+
board = np.array([
|
|
3641
|
+
['3', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '15',' ', ' ', ' ', ' ' ],
|
|
3642
|
+
[' ', ' ', '2', '2', ' ', ' ', ' ', ' ', ' ', ' ', '11',' ', ' ', ' ', ' ', ' ', ' ', '3', '2' ],
|
|
3643
|
+
[' ', ' ', ' ', ' ', '2', ' ', ' ', ' ', '11',' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '2', ' ' ],
|
|
3644
|
+
[' ', ' ', ' ', '2', ' ', ' ', ' ', ' ', ' ', ' ', '6', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ' ],
|
|
3645
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '3', ' ', ' ', ' ', ' ', ' ', ' ', ' ' ],
|
|
3646
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '2', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ' ],
|
|
3647
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '2', ' ', ' ', ' ', ' ', ' ', ' ', ' ' ],
|
|
3648
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '28','4', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ' ],
|
|
3649
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '10',' ', '10',' ', ' ', ' ', ' ', '45',' ' ],
|
|
3650
|
+
[' ', ' ', '3', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ' ],
|
|
3651
|
+
[' ', '22',' ', ' ', ' ', ' ', ' ', '28',' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '17'],
|
|
3652
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ' ],
|
|
3653
|
+
[' ', '8', '3', ' ', ' ', '2', '2', ' ', ' ', ' ', '5', ' ', ' ', '4', ' ', ' ', ' ', ' ', ' ' ],
|
|
3654
|
+
[' ', ' ', ' ', ' ', '4', ' ', ' ', '8', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '2', ' ', ' ', ' ' ],
|
|
3655
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '3', ' ' ],
|
|
3656
|
+
[' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ' ],
|
|
3657
|
+
['2', ' ', ' ', ' ', '12',' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ' ],
|
|
3658
|
+
['2', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ', ' ' ],
|
|
3659
|
+
[' ', ' ', '3', '2', ' ', ' ', ' ', ' ', ' ', ' ', ' ', '60',' ', ' ', ' ', ' ', ' ', '4', ' ' ],
|
|
3660
|
+
])
|
|
3661
|
+
binst = solver.Board(board=board)
|
|
3662
|
+
solutions = binst.solve_and_print()
|
|
3663
|
+
```
|
|
3664
|
+
|
|
3665
|
+
**Script Output**
|
|
3666
|
+
|
|
3667
|
+
```python
|
|
3668
|
+
Solution found
|
|
3669
|
+
0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1
|
|
3670
|
+
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8
|
|
3671
|
+
┌───────────┬───────────────────────────────────────────────────────────┬───┐
|
|
3672
|
+
0│ 3 │ 15 │ │
|
|
3673
|
+
├───────┬───┼───┬───────────────────────────────────────────┬───────────┤ │
|
|
3674
|
+
1│ │ 2 │ 2 │ 11 │ 3 │ 2 │
|
|
3675
|
+
│ │ │ ├───┬───────────────────────────────────────┴───┬───────┼───┤
|
|
3676
|
+
2│ │ │ │ 2 │ 11 │ 2 │ │
|
|
3677
|
+
│ ├───┴───┤ ├───────────────────────┬───┬───┬───────────┴───────┤ │
|
|
3678
|
+
3│ │ 2 │ │ 6 │ │ │ │ │
|
|
3679
|
+
│ ├───────┴───┴───────────────┬───┬───┤ │ │ │ │
|
|
3680
|
+
4│ │ │ │ │ 3 │ │ │ │
|
|
3681
|
+
│ │ │ │ │ │ │ │ │
|
|
3682
|
+
5│ │ │ │ 2 │ │ │ │ │
|
|
3683
|
+
│ │ │ ├───┴───┤ │ │ │
|
|
3684
|
+
6│ │ │ │ 2 │ │ │ │
|
|
3685
|
+
│ │ │ ├───────┤ │ │ │
|
|
3686
|
+
7│ │ 28 │ 4 │ │ │ │ │
|
|
3687
|
+
│ ├───┬───────────────────────┴───┤ │ │ │ │
|
|
3688
|
+
8│ │ │ │10 │10 │ 45 │ │
|
|
3689
|
+
│ │ │ │ │ │ │ │
|
|
3690
|
+
9│ │ 3 │ │ │ │ │ │
|
|
3691
|
+
│ │ │ │ │ │ │ │
|
|
3692
|
+
10│ 22 │ │ 28 │ │ │ │17 │
|
|
3693
|
+
│ ├───┤ │ │ │ │ │
|
|
3694
|
+
11│ │ │ │ │ │ │ │
|
|
3695
|
+
├───────┤ ├───────┬───┬───┬───────────┴───────┤ ├───────────────┬───┤ │
|
|
3696
|
+
12│ 8 │ 3 │ │ 2 │ 2 │ 5 │ │ 4 │ │ │
|
|
3697
|
+
│ │ │ │ │ ├───────────────────┴───┴───────┬───────┤ │ │
|
|
3698
|
+
13│ │ │ 4 │ │ │ 8 │ 2 │ │ │
|
|
3699
|
+
│ ├───┴───────┼───┴───┴───────────────────────────────┴───────┤ │ │
|
|
3700
|
+
14│ │ │ │ 3 │ │
|
|
3701
|
+
│ │ │ ├───┤ │
|
|
3702
|
+
15│ │ │ │ │ │
|
|
3703
|
+
├───────┤ │ │ │ │
|
|
3704
|
+
16│ 2 │ 12 │ │ │ │
|
|
3705
|
+
├───────┤ │ │ │ │
|
|
3706
|
+
17│ 2 │ │ │ │ │
|
|
3707
|
+
├───────┴───┬───────┤ │ │ │
|
|
3708
|
+
18│ 3 │ 2 │ 60 │ 4 │ │
|
|
3709
|
+
└───────────┴───────┴───────────────────────────────────────────────┴───┴───┘
|
|
3710
|
+
Solutions found: 1
|
|
3711
|
+
status: OPTIMAL
|
|
3712
|
+
Time taken: 0.01 seconds
|
|
3713
|
+
```
|
|
3714
|
+
|
|
3715
|
+
**Solved puzzle**
|
|
3716
|
+
|
|
3717
|
+
Applying the solution to the puzzle visually:
|
|
3718
|
+
|
|
3719
|
+
<img src="https://raw.githubusercontent.com/Ar-Kareem/puzzle_solver/master/images/rectangles_solved.png" alt="Rectangles solved" width="500">
|
|
3720
|
+
|
|
3721
|
+
---
|
|
3722
|
+
|
|
3388
3723
|
---
|
|
3389
3724
|
|
|
3390
3725
|
## Why SAT / CP-SAT?
|
|
@@ -3475,3 +3810,6 @@ Issues and PRs welcome!
|
|
|
3475
3810
|
[37]: https://github.com/Ar-Kareem/puzzle_solver/tree/master/src/puzzle_solver/puzzles/unequal "puzzle_solver/src/puzzle_solver/puzzles/unequal at master · Ar-Kareem/puzzle_solver · GitHub"
|
|
3476
3811
|
[38]: https://github.com/Ar-Kareem/puzzle_solver/tree/master/src/puzzle_solver/puzzles/norinori "puzzle_solver/src/puzzle_solver/puzzles/norinori at master · Ar-Kareem/puzzle_solver · GitHub"
|
|
3477
3812
|
[39]: https://github.com/Ar-Kareem/puzzle_solver/tree/master/src/puzzle_solver/puzzles/slitherlink "puzzle_solver/src/puzzle_solver/puzzles/slitherlink at master · Ar-Kareem/puzzle_solver · GitHub"
|
|
3813
|
+
[40]: https://github.com/Ar-Kareem/puzzle_solver/tree/master/src/puzzle_solver/puzzles/yin_yang "puzzle_solver/src/puzzle_solver/puzzles/yin_yang at master · Ar-Kareem/puzzle_solver · GitHub"
|
|
3814
|
+
[41]: https://github.com/Ar-Kareem/puzzle_solver/tree/master/src/puzzle_solver/puzzles/binairo "puzzle_solver/src/puzzle_solver/puzzles/binairo at master · Ar-Kareem/puzzle_solver · GitHub"
|
|
3815
|
+
[42]: https://github.com/Ar-Kareem/puzzle_solver/tree/master/src/puzzle_solver/puzzles/rectangles "puzzle_solver/src/puzzle_solver/puzzles/rectangles at master · Ar-Kareem/puzzle_solver · GitHub"
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
puzzle_solver/__init__.py,sha256=
|
|
2
|
-
puzzle_solver/core/utils.py,sha256=
|
|
1
|
+
puzzle_solver/__init__.py,sha256=y6x9mMvglHDRKhkRXIudfXFgJ0KGBPo3jqi1YT_B6wc,3071
|
|
2
|
+
puzzle_solver/core/utils.py,sha256=BH4b-GZLfYWWZ4QPt1UcuwSX3ntE3bInJtwHd7RnVf4,13459
|
|
3
3
|
puzzle_solver/core/utils_ortools.py,sha256=2xEL9cMEKmNhRD9lhr2nGdZ3Lbmc9cnHY8xv6iLhUr0,10542
|
|
4
4
|
puzzle_solver/puzzles/aquarium/aquarium.py,sha256=BUfkAS2d9eG3TdMoe1cOGGeNYgKUebRvn-z9nsC9gvE,5708
|
|
5
5
|
puzzle_solver/puzzles/battleships/battleships.py,sha256=RuYCrs4j0vUjlU139NRYYP-uNPAgO0V7hAzbsHrRwD8,7446
|
|
6
|
+
puzzle_solver/puzzles/binairo/binairo.py,sha256=sRtflnlGrN8xQ64beRZBGr74R8KptzxYDdFgXuW27pM,4595
|
|
6
7
|
puzzle_solver/puzzles/black_box/black_box.py,sha256=ZnHDVt6PFS_r1kMNSsbz9hav1hxIrNDUvPyERGPjLjM,15635
|
|
7
8
|
puzzle_solver/puzzles/bridges/bridges.py,sha256=15A9uV4xjoqPRo_9CTnoKeGRxS3z2aMF619T1n0dTOQ,5402
|
|
8
9
|
puzzle_solver/puzzles/chess_range/chess_melee.py,sha256=D-_Oi8OyxsVe1j3dIKYwRlxgeb3NWLmDWGcv-oclY0c,195
|
|
@@ -29,16 +30,17 @@ puzzle_solver/puzzles/nonograms/nonograms.py,sha256=1jmDTOCnmivmBlwtMDyyk3TVqH5I
|
|
|
29
30
|
puzzle_solver/puzzles/norinori/norinori.py,sha256=uC8vXAw35xsTmpmTeKqYW7tbcssms9LCcXFBONtV2Ng,4743
|
|
30
31
|
puzzle_solver/puzzles/pearl/pearl.py,sha256=OhzpMYpxqvR3GCd5NH4ETT0NO4X753kRi6p5omYLChM,6798
|
|
31
32
|
puzzle_solver/puzzles/range/range.py,sha256=rruvD5ZSaOgvQuX6uGV_Dkr82nSiWZ5kDz03_j7Tt24,4425
|
|
33
|
+
puzzle_solver/puzzles/rectangles/rectangles.py,sha256=V7p6GSCwYrFfILDWiLLUbX08WlnPbQKdhQm8bMa2Mgw,7060
|
|
32
34
|
puzzle_solver/puzzles/signpost/signpost.py,sha256=-0_S6ycwzwlUf9-ZhP127Rgo5gMBOHiTM6t08dLLDac,3869
|
|
33
35
|
puzzle_solver/puzzles/singles/singles.py,sha256=3wACiUa1Vmh2ce6szQ2hPjyBuH7aHiQ888p4R2jFkW4,3342
|
|
34
36
|
puzzle_solver/puzzles/slant/slant.py,sha256=xF-N4PuXYfx638NP1f1mi6YncIZB4mLtXtdS79XyPbg,6122
|
|
35
37
|
puzzle_solver/puzzles/slant/parse_map/parse_map.py,sha256=dxnALSDXe9wU0uSD0QEXnzoh1q801mj1ePTNLtG0n60,4796
|
|
36
|
-
puzzle_solver/puzzles/slitherlink/slitherlink.py,sha256=
|
|
38
|
+
puzzle_solver/puzzles/slitherlink/slitherlink.py,sha256=_P5IyDKs8gP9aubCW5QStOv4TGf0Hkq7ybyjkxw5n_U,6856
|
|
37
39
|
puzzle_solver/puzzles/star_battle/star_battle.py,sha256=IX6w4H3sifN01kPPtrAVRCK0Nl_xlXXSHvJKw8K1EuE,3718
|
|
38
40
|
puzzle_solver/puzzles/star_battle/star_battle_shapeless.py,sha256=lj05V0Y3A3NjMo1boMkPIwBhMtm6SWydjgAMeCf5EIo,225
|
|
39
41
|
puzzle_solver/puzzles/stitches/stitches.py,sha256=iK8t02q43gH3FPbuIDn4dK0sbaOgZOnw8yHNRNvNuIU,6534
|
|
40
42
|
puzzle_solver/puzzles/stitches/parse_map/parse_map.py,sha256=1LNJkIqpcz1LvY0H0uRedABQWm44dgNf9XeQuKm36WM,10275
|
|
41
|
-
puzzle_solver/puzzles/sudoku/sudoku.py,sha256=
|
|
43
|
+
puzzle_solver/puzzles/sudoku/sudoku.py,sha256=SE4TM_gic6Jj0fkDR_NzUJdX2XKyQ8eeOnVAQ011Xbo,8870
|
|
42
44
|
puzzle_solver/puzzles/tents/tents.py,sha256=iyVK2WXfIT5j_9qqlQg0WmwvixwXlZSsHGK3XA-KpII,6283
|
|
43
45
|
puzzle_solver/puzzles/thermometers/thermometers.py,sha256=nsvJZkm7G8FALT27bpaB0lv5E_AWawqmvapQI8QcYXw,4015
|
|
44
46
|
puzzle_solver/puzzles/towers/towers.py,sha256=QvL0Pp-Z2ewCeq9ZkNrh8MShKOh-Y52sFBSudve68wk,6496
|
|
@@ -46,8 +48,10 @@ puzzle_solver/puzzles/tracks/tracks.py,sha256=98xds9SKNqtOLFTRUX_KSMC7XYmZo567LO
|
|
|
46
48
|
puzzle_solver/puzzles/undead/undead.py,sha256=IrCUfzQFBem658P5KKqldG7vd2TugTHehcwseCarerM,6604
|
|
47
49
|
puzzle_solver/puzzles/unequal/unequal.py,sha256=ExY2XDCrqROCDpRLfHo8uVr1zuli1QvbCdNCiDhlCac,6978
|
|
48
50
|
puzzle_solver/puzzles/unruly/unruly.py,sha256=sDF0oKT50G-NshyW2DYrvAgD9q9Ku9ANUyNhGSAu7cQ,3827
|
|
51
|
+
puzzle_solver/puzzles/yin_yang/yin_yang.py,sha256=WrRdNhmKhIARdGOt_36gpRxRzrfLGv3wl7igBpPFM64,5259
|
|
52
|
+
puzzle_solver/puzzles/yin_yang/parse_map/parse_map.py,sha256=drjfoHqmFf6U-ZQUwrBbfGINRxDQpgbvy4U3D9QyMhM,6617
|
|
49
53
|
puzzle_solver/utils/visualizer.py,sha256=tsX1yEKwmwXBYuBJpx_oZGe2UUt1g5yV73G3UbtmvtE,6817
|
|
50
|
-
multi_puzzle_solver-0.9.
|
|
51
|
-
multi_puzzle_solver-0.9.
|
|
52
|
-
multi_puzzle_solver-0.9.
|
|
53
|
-
multi_puzzle_solver-0.9.
|
|
54
|
+
multi_puzzle_solver-0.9.24.dist-info/METADATA,sha256=mcSsOot7iHAhhc2fangljbrIpGvDsuwc80_ifFRXJ7s,202273
|
|
55
|
+
multi_puzzle_solver-0.9.24.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
56
|
+
multi_puzzle_solver-0.9.24.dist-info/top_level.txt,sha256=exwVUQa-anK9vYrpKzBPvH8bX43iElWI4VeNiAyBGJY,14
|
|
57
|
+
multi_puzzle_solver-0.9.24.dist-info/RECORD,,
|
puzzle_solver/__init__.py
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
from puzzle_solver.puzzles.aquarium import aquarium as aquarium_solver
|
|
2
2
|
from puzzle_solver.puzzles.battleships import battleships as battleships_solver
|
|
3
|
+
from puzzle_solver.puzzles.binairo import binairo as binairo_solver
|
|
3
4
|
from puzzle_solver.puzzles.black_box import black_box as black_box_solver
|
|
4
5
|
from puzzle_solver.puzzles.bridges import bridges as bridges_solver
|
|
5
6
|
from puzzle_solver.puzzles.chess_range import chess_range as chess_range_solver
|
|
@@ -22,6 +23,7 @@ from puzzle_solver.puzzles.norinori import norinori as norinori_solver
|
|
|
22
23
|
from puzzle_solver.puzzles.lits import lits as lits_solver
|
|
23
24
|
from puzzle_solver.puzzles.pearl import pearl as pearl_solver
|
|
24
25
|
from puzzle_solver.puzzles.range import range as range_solver
|
|
26
|
+
from puzzle_solver.puzzles.rectangles import rectangles as rectangles_solver
|
|
25
27
|
from puzzle_solver.puzzles.signpost import signpost as signpost_solver
|
|
26
28
|
from puzzle_solver.puzzles.singles import singles as singles_solver
|
|
27
29
|
from puzzle_solver.puzzles.slant import slant as slant_solver
|
|
@@ -37,7 +39,8 @@ from puzzle_solver.puzzles.tracks import tracks as tracks_solver
|
|
|
37
39
|
from puzzle_solver.puzzles.undead import undead as undead_solver
|
|
38
40
|
from puzzle_solver.puzzles.unequal import unequal as unequal_solver
|
|
39
41
|
from puzzle_solver.puzzles.unruly import unruly as unruly_solver
|
|
42
|
+
from puzzle_solver.puzzles.yin_yang import yin_yang as yin_yang_solver
|
|
40
43
|
|
|
41
44
|
from puzzle_solver.puzzles.inertia.parse_map.parse_map import main as inertia_image_parser
|
|
42
45
|
|
|
43
|
-
__version__ = '0.9.
|
|
46
|
+
__version__ = '0.9.24'
|