Crate connect_four_solver

Source

Structs§

Column
An integer ranging from 0 to 6 representing a column of the connect four board.
ConnectFour
Implementation of the Connect Four game. The board is implemented as to 64 bit masks. It allows for fast checking of winning conditions and legal moves. Apart from being able to play connect four, this type also features some utility functions which can help with implementations of heuristics and solvers.
Solver
Reusing the same solver instead of repeatedly running score in order to calculate similar positions, may have performance benefits, because we can reuse the transposition table.

Functions§

score
Calculates the score of a connect four game. The score is set up so always picking the move with the lowest score results in perfect play. Perfect meaning winning as fast as possible, drawing or loosing as late as possible.