How to use algorithm
-
Instantiate GameTree , tree = GameTree()
-
Construct the tree , tree.constructTree() # creates game tree of specified depth with randomized utilities at each terminal state
-
run the algorithm on tree, tree.minimax() # computes the decision at the root node and all decisions at each level
-
print out utilities at each terminal state, tree.dfs() # performs a depth first search and prints all utility values