Step 1 - Deciding between ionic and covalent bond
In the ionic bond, atoms gain or lose electrons, forming ions, which attract themselves thus resulting in a very strong chemical bond. In the covalent bond, on the other hand, electrons are shared by two atoms, resulting in a molecule.
The ionic bond usually happens between a metal (low ionization energies) and a non-metal (high electron affinities), while covalent bond happens between two or more non-metal atoms.
Therefore, looking at the atoms in the substance we can discover whether it is an ionic or covalent substance.
Step 2 - Using this information to answer the exercise
Note that hydrogen gas (H2) is a molecule. Therefore, its bonds must be covalent. That is so because H is a non-metal. Whenever two non-metals bond, be they different or the same, a covalent bond arises.
Since a covalent bond is the sharing of electrons between atoms, the correct answer is item d) sharing electrons.