valid | R Documentation |
This function checks if the provided number can be placed in the specified row and column in adherence to the rules of the sudoku game.
valid(board, num, row, col)
board |
A 9 by 9 sudoku grid |
num |
A number in 1:9 |
row |
specified row |
col |
specified column |
TRUE or FALSE indicating if placement is valid or not.
b2 <- sample_boards()[[5]] valid(b2, 7, 4, 8)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.