Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optimize Move Evaluation #1

Open
mrdcvlsc opened this issue Sep 8, 2023 · 0 comments
Open

Optimize Move Evaluation #1

mrdcvlsc opened this issue Sep 8, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@mrdcvlsc
Copy link
Owner

mrdcvlsc commented Sep 8, 2023

It might be possible to optimize the move evaluation function by simply recording the previous move position (in 2D index of the board) and check the horizontal, vertical, left & right diagonal lines that only intersect from that point. This approach aims to identify if a straight line of X's or O's has already been formed in these directions, thus determining the game's outcome, instead of exhaustively checking the entire board (each rows, each columns, and each major and minor left and right diagonals).

@mrdcvlsc mrdcvlsc added the enhancement New feature or request label Sep 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant