Pentominos |
A pentomino consists of five equal-sized squares attached edge-to-edge to form some shape. There are twelve possiblepentominos that can be formed in this way (plus their reflections and rotations). A few pentominos are shown below:
XXXXX XXXX XXXX X X X XXX X
Something that has been keeping people occupied since the late 50's is to find a way to form a rectangle of a given size using the 12 different pentominos
Your program needs to only find one solution. If no solution exists, ``No solution." should be printed.
3 5 4 5 5 5 6 5
aaaaabcc deeebbbc ddde*bcc ffde*ggg hffi*ggj hfii*jjj hiikkklj hhkkllll