Alak was invented by the mathematician A. K. Dewdney, and described
in his 1984 book Planiverse. The rules of Alak are simple at
least as Ive (mis?)understood them and implemented them here:
* Alak is a two-player game played on a one-dimensional board with
eleven slots on it. Each slot can hold at most one piece at a time.
Theres two kinds of pieces, which I represent here as x and o
xs belong to one player (called X thats the computer), os to the
other (called O thats you).
* The initial configuration of the board is:
For sake of reference, the slots are numbered from 1 (on the left) to
11 (on the right), and X always has the first move.
* The players take turns moving. At each turn, each player can move
only one piece, once. (This is unlike checkers, where you move one piece
per move but get to keep moving it if you jump an your opponents
piece.) A player cannot pass up on his turn. A player can move any one
of his pieces to the next unoccupied slot to its right or left, which
may involve jumping over occupied slots. A player cannot move a piece
off the side of the board.
* If a move creates a pattern where the opponents pieces are
surrounded, on both sides, by two pieces of the movers color (with no
intervening unoccupied blank slot), then those surrounded pieces are
removed from the board.
* The goal of the game is to remove all of your opponents pieces, at
which point the game ends. Removing all-but-one ends the game as
well, since the opponent cant surround you with one piece, and so will
always lose within a few moves anyway.
A game between X (computer) and a particularly dim O (human):
^ Move 1: X moves from 3 (shown with caret) to 5
(Note that any of Xs pieces could move, but
that the only place they could move to is 5.)
^ Move 2: O moves from 9 to 7.
^ Move 3: X moves from 4 to 6.
^ Move 4: O (stupidly) moves from 10 to 9.
^ Move 5: X moves from 5 to 10, making the board
"xx___xoooxo". The three os that X just
surrounded are removed.
O has only one piece, so has lost.