Explanation:
Electromagnetic wave is the wave in which both magnetic field and the electric field are mutually perpendicular to the direction of the propagation of the wave. It travels with the speed of the light.
It is transverse in nature. It does not need any medium to travel. For example, radio wave. It transmitted to earth from the satellites.
Mechanical wave needs medium to travel. For example, sound wave can travel in solid, liquid and the gas. It travels faster in solid in comparison to liquid.
Sound wave consists of rarefaction and compression. This is longitudinal wave.