Covalent compound has its length that depends on how many atoms linked to form that compound. For an example, we'll know absolutely that decane is longer than methane. Now the question is: How can we determine who's the longer one between two compounds that only have one different atom (Ex: Chloromethane and Bromomethane)?
We have to remember two important things to answer the question above. Electronegativity and Radius of atom. Don't ever think that it is because of its electronegativity chloromethane has a longer length than bromomethane. Electronegativity is the tend of an atom to attract electrons in a bond which is mean the ability of an atom to distribute the electron it has. We know that Chlorine atom is more electronegative than Bromine. But, we also have to know that Bromine is bigger than chlorine.
Just imagine this: You have four marble. Two marbles (A and B) have the same size while the others have different size (C and D). Now compare molecule of marble AC and marble BD (size of D > C). You can conclude that molecule BD is longer than AC, can't you?
Now the pictures below compare the size of HCl, HBr, and HI: