I have tried writing the algorithm by referring this.
But i am getting Error of StackOverFlow.
Help me out to find what is wrong in the program? Is it the recursion part?
public void beginSolving(int board[][],int x,int y){
int i = 1;
if(unassignedCell(board,x,y)){
board[x][y] = i;
if(isValidCell(board,y,x,i)){
board[x][y] = i;
}
if(!isValidCell(board,y,x,i)){
board[x][y] = 0;
i++;
}
} else {
while(x<9){
beginSolving(board,x++,y);
if(x==9){
x = 1;
beginSolving(board,x,y++);
if(y==9){
}
}
}
}
}