Rock cycle

The rock cycle is how rocks of one kind change into rocks of another kind.
There are three main kinds of rocks: igneous rock, metamorphic rock, and sedimentary rock. Each of these rocks can change into the other kinds by physical processes: cooling, melting, heat, weathering/erosion, compacting (squeezing tightly together), cementing, and pressure.
When heated deep under ground, rocks become magma (liquid rock). Above ground, it is called lava. Sediment, the particles from rock erosion and weathering, is the basis for sedimentary rock of the future.
Igneous rock is hardened magma, which can happen above or below ground. It can melt into magma, erode into sediment, or be pressed tightly together to become metamorphic.
Metamorphic rock is igneous or sedimentary rock that has been heated and squeezed. It can erode into sediment or melt into magma. It is formed under extreme pressure and temperature deep inside mountain chains.
Sedimentary rock is compacted sediments which can come from any of the other rocks, plus remains of living things. It can erode back into sediment, or be pressurized into metamorphic rock and can be melted to magma, which forms igneous rocks.
These processes can occur in different orders, and the cycle goes on forever. Earth has several processes for changing rocks. Wind and water can create sediment from rocks, and movement of one tectonic plate against another creates enormous heat and pressure which affects rocks greatly. Subduction converts all kinds into magma, which eventually rejoins the cycle as igneous rocks.