I have to think about this more, but on a very quick first reading it seems that you have missed a strategy that I have needed in order to solve some tough PileOn games.
And that is breaking up groups of 2 or 3 that you already have built, or dealt. Given these 3 piles to start with A B X X C D X E F G X B (and then some more) the correct way to solve things may be to put E and B in the empty slots, take one X from the first pile and put it on the second and take the other and put it on the third. Then move the B from the empty slot back to pile one. The same thing has also been needed when piles are A X X B as well. Does your algorithm handle that, or does it assume that things that are stuck together belong together? Laura _______________________________________________ Edu-sig mailing list Edu-sig@python.org http://mail.python.org/mailman/listinfo/edu-sig