public static void Main()
Console.WriteLine("Sudoku Resolver by Chris Randle (csharpforevermore@gmail.com) September 2023");
static int GetFactorial(int number)
for(int i = 1; i< number; i++)
public static class Puzzle
public static int[][] Board = new [] {
new [] {5,6,8,0,1,0,0,4,7},
new [] {0,0,2,0,0,7,0,0,5},
new [] {0,0,7,0,5,4,8,6,0},
new [] {0,2,6,0,4,5,7,0,0},
new [] {0,5,0,7,2,0,4,3,0},
new [] {0,7,0,8,0,0,5,2,6},
new [] {0,8,5,0,7,9,0,0,0},
new [] {2,0,9,5,3,8,0,7,0},
new [] {7,3,0,1,0,2,9,5,8}
public static int[][] Solution = new [] {
new [] {5,6,8,9,1,3,2,4,7},
new [] {3,4,2,6,8,7,1,9,5},
new [] {1,9,7,2,5,4,8,6,3},
new [] {9,2,6,3,4,5,7,8,1},
new [] {8,5,1,7,2,6,4,3,9},
new [] {4,7,3,8,9,1,5,2,6},
new [] {6,8,5,4,7,9,3,1,2},
new [] {2,1,9,5,3,8,6,7,4},
new [] {7,3,4,1,6,2,9,5,8}
public static bool IsCompleted()
return (Puzzle.Board == Puzzle.Solution);
public static bool IsContainsZeroes()