game. The game class provides a framework for two-player
games such to be implemented as derived classes. Within the framework,
the human user will be one player in the game and the computer will be
the other player (using a game strategy called
minimax with alpha-beta pruning.
The textbook describes the game class in detail and also
provides a derived class to play Connect4. Here are the
relevant files:
chess class will take
more work than implementing the derived connect4 class.
game class does not allow randomness.
evaluate function for your
derived class, you should concentrate on having a quick evaluation
function rather than a complicated function that attempts to
anticipate the consequences of subsequent moves. The anticiaption of
subsequent moves is already built into the minimax strategy of the
base game class, and the evaluation function that you
write for the derived class is never used until the base class has
already traversed several layers down the tree of possible moves.
game class, I would like to hear about it. So far, I have
implemented: