Solver for crossteaser puzzle