How to implement a transposition table for connect 4?
问题 I'm making a connect 4 AI in python, and I'm using minimax with iterative deepening and alpha beta pruning for this. For greater depths it's still quite slow, so I wanted to implement a transposition table. After reading up on it I think i get the general idea but i haven't been able to quite make it work. Here's part of my code: (the maximizing part of the minimax): if(isMaximizing): maxEval = -99999999999 bestMove = None # cache.get(hash(board)) Here's where i'd check to see if the hash is