Skip to content

Commit

Permalink
Ripping out unneeded Array of Threads
Browse files Browse the repository at this point in the history
  • Loading branch information
redsquirrel committed Jan 2, 2009
1 parent d016363 commit 971c6bd
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions sudoku/brain.rb
Expand Up @@ -22,15 +22,14 @@ def solvers(blanks)
end

def guess(board, blanks, state)
threads = []
brain_cells = sorted_cells_with_coords_from(blanks)
brain_cells.each do |brain_cell, coords|
brain_cell.size.times do |i|
board[coords.last][coords.first] = brain_cell[i]
if state.finished
return
else
threads << Thread.new do
Thread.new do
think(board, self, state)
end
end
Expand Down

0 comments on commit 971c6bd

Please sign in to comment.