Limestone is a common type of carbonate sedimentary rock. It is composed mostly of the minerals calcite and aragonite, which are different crystal forms of calcium carbonate. Limestone forms when these minerals precipitate out of water containing dissolved calcium. This can take place through both biological and nonbiological processes, though biological processes have likely been more important for the last 540 million years. Limestone often contains fossils, and these provide scientists with information on ancient environments and on the evolution of life.