cancel
Showing results for 
Search instead for 
Did you mean: 

Sudoku Solver

AvinashM
Level 2

Hi,

I am learning Blue Prism and I am trying to solve 4x4 and 9x9 sudoku using Blue Prism.

Can some one please help me with this.

Thanks.



------------------------------
Avinash M
------------------------------
1 BEST ANSWER

Best Answers

PvD_SE
Level 12

Hi Avinash,

While I can solve the Sudoku for you, I see no real business interest in creating a process to do so, so I won't. Instead, I can give you a summary.

What you probably want to do is to figure out how you would solve the Sudoku in the most efficient manner, than re-trace you steps and implement these steps in your process.

There's a number of simple rules you can apply to save most of these puzzles, horizontal uniqueness, vertical uniqueness, uniqueness within a block. Then you have the exclusion rules that tell you what values are impossible. Combining all of these rules probably solves about 99% of the puzzles. There are a lot of articles and instructions on this on the interweb.

To get you started in BP, you'd have to map the UI for your Sudoku puzzle, which is somewhere on the internet I assume. You could use the BP Object Modeller to do the mapping. Then you read whatever is on the Sudoku UI into your process, and simply apply the steps described above for solving it, slowly populating the missing values.

As usual, any process is only as clever as the one who wrote it. So if your process fails to solve the puzzle, you have to improve the quality of the steps to solving one. 



------------------------------
Happy coding!
---------------
Paul
Sweden
------------------------------
Happy coding!
Paul, Sweden
(By all means, do not mark this as the best answer!)

View answer in original post

1 REPLY 1

PvD_SE
Level 12

Hi Avinash,

While I can solve the Sudoku for you, I see no real business interest in creating a process to do so, so I won't. Instead, I can give you a summary.

What you probably want to do is to figure out how you would solve the Sudoku in the most efficient manner, than re-trace you steps and implement these steps in your process.

There's a number of simple rules you can apply to save most of these puzzles, horizontal uniqueness, vertical uniqueness, uniqueness within a block. Then you have the exclusion rules that tell you what values are impossible. Combining all of these rules probably solves about 99% of the puzzles. There are a lot of articles and instructions on this on the interweb.

To get you started in BP, you'd have to map the UI for your Sudoku puzzle, which is somewhere on the internet I assume. You could use the BP Object Modeller to do the mapping. Then you read whatever is on the Sudoku UI into your process, and simply apply the steps described above for solving it, slowly populating the missing values.

As usual, any process is only as clever as the one who wrote it. So if your process fails to solve the puzzle, you have to improve the quality of the steps to solving one. 



------------------------------
Happy coding!
---------------
Paul
Sweden
------------------------------
Happy coding!
Paul, Sweden
(By all means, do not mark this as the best answer!)