Solving Mamono Sweeper requires a constraint satisfaction solver. (or is MUCH more easily solved that way) Unfortunately, there aren't really any in Perl. While there are several powerful ones in Python: * http://numberjack.ucc.ie/ -- an interface to several well-developed C libraries * https://github.com/python-constraint/python-constraint