So I did finish getting minimax based tic-tac-toe AI to work just now:
There was a fair bit of debugging (for example I had min and max mixed up because I thought color 1 corresponded to white, when it actually corresponded to black), I think I will need to design and name parts of the code more carefully before writing them out to avoid this repeating and becoming a big problem later on.
The next step is to upgrade this to a connect-4 game with AI because then I'll need to be using alpha-beta pruning, since its search space (while still very small) is too big for minimax to work. It will also be a useful step so that I can redesign the code into something more flexible and clear.
No comments:
Post a Comment