expand sudoku

This commit is contained in:
samerbam 2023-08-23 09:18:03 -04:00
parent 4640a4061d
commit ca2a4a55cc

View File

@ -41,29 +41,29 @@ def generate_sudoku():
def expandLine(line): def expandLine(line):
# return line[0]+line[5:9].join([line[1:5]*(base-1)]*base)+line[9:13] # return line[0]+line[5:9].join([line[1:5]*(base-1)]*base)+line[9:13]
# return line[0]+line[3:7].join([line[1:3]*(base-1)]*base)+line[3:5] return line[0]+line[3:7].join([line[1:3]*(base-1)]*base)+line[3:5]
# return line[0]+line[3:5].join([line[1:3]*(base-1)]*base)+line[5:7] # return line[0]+line[3:5].join([line[1:3]*(base-1)]*base)+line[5:7]
return line[0]+line[4:7].join([line[1:4]*(base-1)]*base)+line[7:10] # return line[0]+line[4:7].join([line[1:4]*(base-1)]*base)+line[7:10]
# line0 = expandLine("╔═══╤═══╦═══╗") line0 = expandLine("╔═══╤═══╦═══╗")
# line1 = expandLine("║ . │ . ║ . ║")
# line2 = expandLine("╟───┼───╫───╢")
# line3 = expandLine("╠═══╪═══╬═══╣")
# line4 = expandLine("╚═══╧═══╩═══╝")
# line0 = expandLine("╔═╤═╦═╗")
# line1 = expandLine("║.│.║.║")
# line2 = expandLine("╟─┼─╫─╢")
# line3 = expandLine("╠═╪═╬═╣")
# line4 = expandLine("╚═╧═╩═╝")
# line0 = expandLine("╔═╤═╦═╗")
# line1 = expandLine("║.│.║.║")
# line2 = expandLine("╟─┼─╫─╢")
# line3 = expandLine("╠═╪═╬═╣")
# line4 = expandLine("╚═╧═╩═╝")
line0 = expandLine("╔══╤══╦══╗")
line1 = expandLine("║ . │ . ║ . ║") line1 = expandLine("║ . │ . ║ . ║")
line2 = expandLine("╟──┼──╫──╢") line2 = expandLine("╟───┼───╫───╢")
line3 = expandLine("╠══╪══╬══╣") line3 = expandLine("╠═══╪═══╬═══╣")
line4 = expandLine("╚══╧══╩══╝") line4 = expandLine("╚═══╧═══╩═══╝")
# line0 = expandLine("╔═╤═╦═╗")
# line1 = expandLine("║.│.║.║")
# line2 = expandLine("╟─┼─╫─╢")
# line3 = expandLine("╠═╪═╬═╣")
# line4 = expandLine("╚═╧═╩═╝")
# line0 = expandLine("╔═╤═╦═╗")
# line1 = expandLine("║.│.║.║")
# line2 = expandLine("╟─┼─╫─╢")
# line3 = expandLine("╠═╪═╬═╣")
# line4 = expandLine("╚═╧═╩═╝")
# line0 = expandLine("╔══╤══╦══╗")
# line1 = expandLine("║. │. ║. ║")
# line2 = expandLine("╟──┼──╫──╢")
# line3 = expandLine("╠══╪══╬══╣")
# line4 = expandLine("╚══╧══╩══╝")
symbol = " 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ" symbol = " 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ"
nums = [ [""]+[symbol[n] for n in row] for row in board ] nums = [ [""]+[symbol[n] for n in row] for row in board ]