Skip to content

Commit 66f16cc

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent a5f1655 commit 66f16cc

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

backtracking/minimax.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,9 @@ def _winning_player(board: Board) -> str | None:
134134
"""
135135
lines = (
136136
# rows
137-
board[0], board[1], board[2],
137+
board[0],
138+
board[1],
139+
board[2],
138140
# columns
139141
[board[0][0], board[1][0], board[2][0]],
140142
[board[0][1], board[1][1], board[2][1]],
@@ -311,8 +313,8 @@ def _play_game() -> None:
311313
demo_scores = [3, 5, 2, 9, 12, 5, 23, 23]
312314
result = minimax(3, 0, True, demo_scores)
313315
print(f"Scores : {demo_scores}")
314-
print(f"Optimal val : {result}") # Expected: 12
316+
print(f"Optimal val : {result}") # Expected: 12
315317

316318
# --- Demo: Tic-Tac-Toe interactive ---
317319
print("\nLaunching Tic-Tac-Toe …")
318-
_play_game()
320+
_play_game()

0 commit comments

Comments
 (0)