此内容没有您所选择的语言版本。
Chapter 25. Sudoku Example
25.1. Sudoku Example: Loading the Example
复制链接链接已复制到粘贴板!
Procedure 25.1. Task
- Opensudoku.drlin the IDE.
- Executejava org.drools.examples.DroolsExamplesAppand click onSudokuExample. The window contains an empty grid, but the program comes with a number of grids stored internally which can be loaded and solved.
- Click onto load one of the examples. All buttons are disabled until a grid is loaded. Loading the Simpleexample fills the grid according to the puzzle's initial state.
- Click on theSolvebutton and the JBoss Rules engine will fill out the remaining values. The buttons will be inactive again.
- Alternatively, click on theStepbutton to see the next digit found by the rule set. The Console window will display detailed information about the rules which are executing to solve the step in a readable format like the example below:Copy to Clipboard Copied! Toggle word wrap Toggle overflow 
- Click on theDumpbutton to see the state of the grid. The cells show either the established value or the remaining possible candidates. See the example below:Copy to Clipboard Copied! Toggle word wrap Toggle overflow