I was practising interesting problems from past problem solving contests when I found this one. I guess that I should find some hash functions to find the candidates and check them by hand. I tried writing down the degrees and solved the 1st part, I1 and D6, but I am stuck at 2nd and 3rd part. I also found the solution booklet but it doesn't contain the exact solutions.
What are the exact solutions for 2nd and 3rd parts?
The original problem statement:
The input file contains a coordinate grid with 10 × 10 similar-looking shapes. Among those 100 shapes there are exactly three matching pairs of shapes:
- Two shapes are identical. (One can be obtained from the other by rotation and translation only.)
- Two shapes are mirror images of each other. (They are not identical as defined above, but one can be obtained from the other by flipping it once and then rotation and/or translation.)
- Two shapes are complements of each other. (Explained below.)
As you can see from the input file, the shapes are actually pictures of simple graphs on 7 vertices. “Complements” should be interpreted in that sense. Two shapes are complements of each other if one of them can be rotated and translated – without flipping – and placed on top of the other in such a way that their vertices coincide and each pair of vertices is connected by an edge in exactly one of the two graphs.