NAME
NIM - mathematical games
SYNOPSYS
use Games::NIM;
$game = new Games::NIM;
$game->play();
DESCRIPTION
Currently you can only play on the command line with the built in interface.
Send your feedback so I now how to improve.
RULES
In all the games there are several groups of something, let's call them stones.
There are 2 players who take away a few stones on every turn according to some rules.
They always have to take away at leas one stone.
The winner is eihter the one who takes the last stone, or the other player :)
depending on the game.
- 1 simple
-
There is one group of (n) stones. There is a list of number Each player can take 1,2, .. k stones at a time.
k is defined when we start the game.
The winner is who takes the last stone.
- 2 not implemented yet
-
There is one group of (n) stones.
Each player can take a few stones at a time where the possible numbers are listed at the beginning of the game. The list can contain any of the values between 1 and n E.g. it can be only 3 or 3 and 7, or ...
The winner is who takes the last stone.
Special cases are: (k, k+1) (1, k) (k, q)
- 3 not implemented yet
-
There are more groups, in each group there are a few stones. Each player can can take either the same number from all groups or any number from one group. The winner who takes the last one
- 4 not implemented yet
-
There are more groups Any number from any number of groups, but the same number from each group. The winner who takes the last one.
- 5 not implemented yet: Chocolate eating
-
There is a chocolate of n*m cubes Two people are eating the chocolate by pointing on one of the cubes and eating everything to the right and below in the chocolate: e.g. inthe following case I pointed to the cube signed with an x oooooo oooxo oooo oo
result:
oooooo ooo ooo oo
The game ends when there are no more chocolate The winner is who remains without chocolate. (The one who takes the last chocolate loses)
AUTHORS
Gabor Szabo <gabor@tracert.com>
COPYRIGHT
The NIM module is Copyright (c) 2001 Gabor Szabo. Israel All rights reserved.
You may distribute under the terms of either the GNU General Public License or the Artistic License, as specified in the Perl README file.
ACKNOWLEDGEMENTS
Dr. Zoltan Dienes for his book