First I realised that the square's value had to be 2 larger than the triangle's because of the bottom two rows. This meant I could work out their values because of the top row (I knew the average had to be 7 so the square had to be worth 8 and the triangle had to be worth 6). I could check this by trying 8+8+8+6=30 on the 2nd column. I could then work out the circle's value because of the bottom row (20-8=12, 12/3=4=the value of the circle). This I could check by trying 6+4+4+4=18 on the 3rd row. Then I could work out what the hexagon was worth because of the 3rd column (23-8=15, 4+4=8, 15-8=7=the value of the hexagon). I could check this by trying 8+8+7+7=30 on the 2nd row. Finally I had to work out the value of the ? by adding up the two circles, hexagon and triangle (4+4+7+6) which came to 21.
triangle = 6
square = 8
circle = 4
hexagon = 7
? = 21