How cold air is less dense in one case and more dense in another case when compared with warm air? There are two different and contradicting explanations given. Which one is correct?
Explanation 1:  Cold air is more denser than hot air because ,when cold air of some density, say 'd' is heated, the molecules/atoms move apart from each other and so the volume expands. As mass of the air hasn't changes and the volume has increased, hot air is less denser than cold air.
Explanation 2: Hot air is more denser than cold air because ,air mostly comprises Oxygen(~20%) and Nitrogen(~78%). So this air, when starts holding water (i.e when it starts becoming cold), few O2(atomic mass 16 units) and N2(atomic mass 14 units) molecules are replaced by H20 (atomic mass 10 units). So, by Avogadro's law, for given volume of air at same temp and pressure and same number of molecules, cold air has lesser weight(H20 has lesser atomic mass) than hot air.
Which of the above two is correct? What causes sea breeze??
Is it that the second explanation is a special case of water acting as cooling agent, otherwise first case is true. 
 A: The equations for the density of air are available on the engineering toolbox site. The density of dry air is approximately given by:
$$ \rho_{dry} = \frac{0.0035\,P_0}{T} $$
where $P_0$ is the pressure and $T$ is the temperature. The density of moist air is approaximately given by:
$$ \rho_{wet} = \rho_{dry}\,\frac{1 + x}{1 + 1.609 x} $$
where $x$ is the mass fraction of water. Just for fun I calculated these in Excel assuming that $P_0 = 101325$ Pa and got:

The first table shows the density in kg/m$^3$ while the second table is the same data but as a fraction of the density of dry air at $0$ºC.
The reason for the blanks in the table is that for any temperature there is a maximum amount of water that the air will hold. Again this is available from the engineering toolbox site. I have chosen the values of $x$ to be the maximum values at the temperatures 273K, 278K, and so on, so the bottom left portion of the table is empty.
I found the results rather surprising. The effect of humidity and temperature are almost equal in their effect - I had not expected humidity to have that big an effect.
This is all good fun, but it doesn't have any great bearing on the sea breeze. because the land is hotter than the sea the density of the air on the land is lower so it rises and pulls in air from the sea - hence the sea breeze. The moisture content of the air remains constant as the air flows, so all that changes is the temperature not the moisture content.
