Expand description
Code for handling moves.
This module contains code for handling moves in Nim games,
such as calculating the resulting position after a move is applied,
determining if a move is valid, and generating all possible moves
for a given position.
Enums§
- Move
Error - Errors which may occur when applying a move
Functions§
- apply_
move - Applies a move to a position, if the move is valid
- apply_
move_ ⚠unchecked - Applies a move to a position, even if the move is invalid
- calculate_
legal_ moves - Generate all possible (legal) moves for a given position
- check_
move - Determine if a move is valid for a given position