Skip to content

Commit 3e548fd

Browse files
author
Christian Bender
committed
added random seed in function chooseRandomMoveFromList(...)
1 parent 51091ba commit 3e548fd

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

TicTacToe.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ def getPlayerMove(board):
8181
def chooseRandomMoveFromList(board, movesList):
8282
# Returns a valid move from the passed list on the passed board.
8383
# Returns None if there is no valid move.
84+
random.seed()
8485
possibleMoves = []
8586
for i in movesList:
8687
if isSpaceFree(board, i):

0 commit comments

Comments
 (0)