Code for sudoku solver