C6H10 is an alkene with the double bond present in any place in the molecule.
C5H6 is for sure a diene. At first I thought it's an alkyne, but alkynes don't have such a general formula. This formula matches with that of a ring. With five carbons, I'd place my bet on cyclopentadiene.