A simple Constraint Programming implementation
bor0.wordpress.com