Rocks:

The Earth is made of rock. The term rock means a collection of minerals within a matrix. A mineral is a naturally occurring compound or sometimes element that always has the same chemical composition no matter where it is found. A rock is an aggregate of one or more minerals, and depending on what conditions under which it was formed, may vary in composition. For example, granite, which is an igneous rock, generally has three minerals: quartz, feldspar, and amphibole. There are three major types of rocks, which differ in the places of origin and in the geological processes by which they formed. Such rocks include sedimentary, igneous, and metamorphic.
Three Major Types of Rocks:

Molten rock or magma may migrate upward near the surface of the Earth and reside within a magma chamber. Sometimes, the magma releases volatile gases which create extreme pressures within the magma chamber. In such cases, the magma is forced upward and spewed out of a volcano. If gases are less volatile, then the magma within the chamber may slowly cool and eventually solidify. It may take several thousands of years for a magma chamber to transform into rock. Such rocks are called igneous rocks.
Igneous Rocks:

Solidified magma gives rise to crystalline rock. The grain of the rock may be course (large crystals) or fine (small crystals) depending on how hot the magma was and how long it took to solidify. In the photo to the left, the crystal grains of this granitic rock can be observed. The course-grained pink crystals are Potassium Feldspar, also known as K-Feldspar. The lighter-colored course-grained crystals are quartz, while the darker ones are amphibole. Sometimes, biotite mica may be present instead of amphibole. Geologists describe the early rocks of the Earth as primary rocks. They include basalt which makes up many of the islands today and the ocean floor and granite which makes up the continents.
Sedimentary Rocks:

At the surface, wind, rain and other conditions have eroded these rocks, thus producing clastic sedimentary rocks. And, as a result, these formed the first sandstones, gravels and beach conglomerates. Through weathering processes and erosion, these surface rocks broke down into smaller particles that eventually got washed away (transported) by water, rain, river or seawater. As the energy of the water significantly reduced, the particles (clasts) settled and were deposited into layers. Through time, the layers compacted together to form sedimentary rocks, such as sandstones, limestones, and shales.
Metamorphic Rocks:

If sedimentary rocks are buried deep underground, they can be transformed into metamorphic rocks by very high temperatures and pressures. Baking, partial-melting, folding, and fracturing produced groups of metamorphic rocks ranging from low-grade slate to high-grade schist and gneiss. Note that "grade" is a measure of the intensity of deformation or degree of baking. The higher the grade, the greater the heat or pressure that formed the metamorphic rock. Metamorphic rocks can also undergo weathering and erosion to form again as sedimentary rocks, thus representing the rock cycle and the many ways in which rocks can change from one to another.