Molarity of a substance is Number of moles of that substance per litre of solution:
here the substance is water and the solution is also water.
density of water is 1gm/ml
so in 1 litre amount of water present 1000ml = density * volume = 1000 grams
now the molecular weight of water is 18 gm/mole
hence total moles = 1000/18 = 55.55 moles
so water has 55.55 moles per litre
so the molarity of pure water is 55.55 M