Back to [Home]
The package contains a few things besides the solver.
You can have the positions generated and counted, without storing them. This takes about as long as rebuilding the positions from the ppos file, but for small arenas, it is convenient:
bash genall.sh 6 5 Total positions: 462
Of course, you could calculate them too. It takes factorials, so you have to be careful how you do it, but it's
(cols + rows)!/cols!*rows!
Once you have a soltuion in a csort-file, you can generate counts of N-positions with multiple winning moves.
bash chompstats.sh 6 5 Be patient, please. This can take a while. Done. Result is in the file 6x5-stats
You can look in the file whose name is given...
cat 6x5-stats 35 0 250 1 132 2 44 3
In this case, you find there were 44 positions with 3 winning moves, but as usual, most of the winnable positions could be won in just 1 or 2 ways. With bigger arenas, even more wins will show up, but they are very rare, and the percentages don't change a lot.