public static boolean verifySudoku(int[][] solution);
Write a client program that takes a filename as a command-line argument,
whose contents represent a solution to a sudoku puzzle, and output whether
the solution is correct. You can assume the files contents always contain 81
numbers whose values are between 1 and 9.
Sudoku.java
.java Sudoku sudoku1.txt
):
The solution contained within 'sudoku1.txt' is correct.
java Sudoku sudoku2.txt
):
The solution contained within 'sudoku2.txt' is incorrect.
N x M
matrix. The rest of
the contents are characters: 's' is the start, 'g' is the goal, 'x' is an
obstacle, and '.' is an empty cell. Solve this problem with a recursive
function. When outputting the solution, show the entire maze with all of the
'.'s replaced with 'p' if they lie along your solution path. You may assume
the contents of the file are always correct.
MazeSolver.java
.java MazeSolver maze1.txt
):
Solution path exists
. x . x p p p p p
. . . x g x x x p
x . x . x . . . p
x s p p p x x x p
. . x x p p p p p
java MazeSolver maze2.txt
):
Solution path does not exist