The formation of dew and fog is due to the process of condensation. Condensation occurs when water vapor in the air cools down and turns into liquid water droplets, which form dew or fog. This happens when the air temperature drops, and the moisture in the air condenses into tiny water droplets that we can see as dew or fog.
Thus, the correct answer is condensation.