private bool SolveAux(Grid initial) { if (initial.IsSolved()) return true; int pos = GetNextPosition(initial); var listMoves = initial.GetAvailableNumbersFor(pos); foreach (var move in listMoves) { initial.Place(move,pos); if (SolveAux(initial)) return true; initial.Place(0,pos); } return false; }