Sudoku Solver

Understand and solve the interview question "Sudoku Solver".

Description

Write a program to solve Sudoku by filling the empty cells. We will be given a 2D array representing a Sudoku puzzle. For a correct solution each of the digits 1-9 must only occur once in each:

  • Row
  • Column
  • Nine 3x3 sub-boxes of the grid

Let us take a look at an example:

Level up your interview prep. Join Educative to access 70+ hands-on prep courses.