For covalent bonds, bond energies and bondlengths depend on many factors: electron afinities, sizes of atoms involved in the bond, differences in their electronegativity, and the overall structure of the molecule. There is a general trend in that the shorter the bondlength, the higher the bond energy. However, there is no formula to show this relationship, because the variation is widespread.