The object of the game is to have all the tiles removed from the board. You can remove any pair of tiles that are "good neighbors" - that is, are adjacent (including diagonal) and have corresponding parts.
This image is a schematic representation, not a screenshot from the game. Screenshots are platform specific. You can see screenshots in the store.