Step 1: Coal forms from the accumulation and compaction of plant remains in swamps over long periods of time.
Step 2: This layered, organic accumulation process is the same process that forms sedimentary rocks, so coal is classified as an organic sedimentary rock.
Step 3: It is not formed by heat and pressure acting on existing rock (metamorphic), by ice action (glacial), or by cooling magma (igneous), so the answer is Sedimentary type.