From 24b246f7250eb772deb14aaf9c10e917b08b8d4b Mon Sep 17 00:00:00 2001 From: Andrew Rowley Date: Thu, 7 Mar 2024 12:27:51 +0000 Subject: [PATCH] Fix this (not sure why it is like this) --- sudoku/sudoku.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/sudoku/sudoku.py b/sudoku/sudoku.py index fbc3795..f8626b3 100644 --- a/sudoku/sudoku.py +++ b/sudoku/sudoku.py @@ -202,7 +202,7 @@ def activate_visualiser(old_vis): # # set up the inter-cell inhibitory connections # -def interCell(): +def interCell(x, y, r, c, connections): """ Inhibit same number: connections are n_N squares on diagonal of weight_cell() from cell[x][y] to cell[r][c] """ @@ -225,14 +225,14 @@ def interCell(): for y in range(9): for r in range(9): if r != x: - interCell() # by row... + interCell(x, y, r, y, connections) # by row... for c in range(9): if c != y: - interCell() # by column... + interCell(x, y, x, c, connections) # by column... for r in range(3 * (x // 3), 3 * (x // 3 + 1)): for c in range(3 * (y // 3), 3 * (y // 3 + 1)): if r != x and c != y: - interCell() # & by square + interCell(x, y, r, c, connections) # & by square conn_intC = p.FromListConnector(connections) p.Projection(cells, cells, conn_intC, receptor_type="inhibitory")