I was looking at the problem Magic Square
I am sure with some loop and if condition this problem can be solve, but I am interested to know if there is any know algorithm / datastructure to solve this problem. I am not interested in exact solution, but any hint toward algorithm/datastructure would help.
I was looking at the problem Magic Square I am sure with some loop
Share
That is a description of sudoku, generalized to squares of different size. There are several known sudoku solvers; you would have to adapt them.