MCPcopy Create free account
hub / github.com/ActiveState/code / IsTerminalNode

Function IsTerminalNode

recipes/Python/580698_Reversi_Othello/recipe-580698.py:87–92  ·  view source on GitHub ↗
(board, player)

Source from the content-addressed store, hash-verified

85
86# if no valid move(s) possible then True
87def IsTerminalNode(board, player):
88 for y in range(n):
89 for x in range(n):
90 if ValidMove(board, x, y, player):
91 return False
92 return True
93
94def GetSortedNodes(board, player):
95 sortedNodes = []

Callers 9

MinimaxFunction · 0.85
AlphaBetaFunction · 0.85
AlphaBetaSNFunction · 0.85
NegamaxFunction · 0.85
NegamaxABFunction · 0.85
NegamaxABSNFunction · 0.85
NegascoutFunction · 0.85
NegascoutSNFunction · 0.85
recipe-580698.pyFile · 0.85

Calls 2

rangeFunction · 0.85
ValidMoveFunction · 0.85

Tested by

no test coverage detected