Skip to content

Commit 518881c

Browse files
committed
Correct the snippet in Tic-tac-toe explanation
Fixes satwikkansal#81
1 parent 169fa2f commit 518881c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -530,7 +530,7 @@ And when the `board` is initialized by multiplying the `row`, this is what happe
530530
We can avoid this scenario here by not using `row` variable to generate `board`. (Asked in [this](https://github.com/satwikkansal/wtfpython/issues/68) issue).
531531
532532
```py
533-
>>> board = [(['']*3)*3] # board = = [['']*3 for _ in range(3)]
533+
>>> board = [['']*3 for _ in range(3)]
534534
>>> board[0][0] = "X"
535535
>>> board
536536
[['X', '', ''], ['', '', ''], ['', '', '']]

0 commit comments

Comments
 (0)