What determines the number of covalent bonds that an atom can form

what determines the number of covalent bonds that an atom can form