how sedimentary rocks form
1. igneous rocks: formed by the cooling and hardening of magma (molten rock) from inside Earth. 2. sedimentary rocks: formed by the compaction and cementing of layers of sediment (rock fragments, plant and animal remains, minerals from water).