7 worms, 3 beetles, 2 lizards
I found this by first doing the calculations for the number of legs (26). First, I added the legs for the 3 beetles together to get 18 legs. Then I added the legs for 2 lizards (8) to the beetles’ legs to get 26 legs in total.To find the number of heads I added the number of lizard heads (2) and beetles heads (3) to get five heads. Then I added the 7 worm’s heads to the lizard and beetles heads to get 12 heads in total.