Modified logic.scramblePuzzle so that solvability is now guaranteed