The attraction between the shared electrons and the nuclei that holds the molecules together in the second energy level of phosphorus atom is a covalent bond. Electrons are kept in the orbit around the nucleus by the electromagnetic force and the protons in the nucleus are held in place by the strong nuclear force, which overcomes the electromagnetic repulsion.