When two atoms combine, they form either a molecule or a compound through chemical bonds. The most common types of bonds are covalent bonds, where atoms share electrons, and ionic bonds, where one atom donates electrons to another, creating charged ions that attract each other. In covalent bonding, the atoms share pairs of electrons to achieve stability, forming molecules such as water (H2O). In ionic bonding, the atoms form a lattice structure like in sodium chloride (NaCl), which is a compound but not an independent molecule. Both bonding types result in a more stable electron configuration for the atoms involved.
