Skip to content

Commit 8e2352a

Browse files
committed
♻️ (sudoku): fix copy reference
1 parent 39fddef commit 8e2352a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/game/puzzle.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ func solveCount(board *Board, limit int) int {
7474

7575
// hasUniqueSolution - 是否具有唯一解
7676
func (board *Board) hasUniqueSolution() bool {
77-
copyBoard := *board
77+
copyBoard := board.Clone()
7878
count := solveCount(&copyBoard, 2)
7979
return count == 1
8080
}

0 commit comments

Comments
 (0)