When an airplane is flying at subsonic speed, all of the air flowing around the airplane is at a velocity of less than the speed of sound (known as Mach 1). Keep in mind that the air accelerates when it flows over certain parts of the airplane, like the top of the wing, so an airplane flying at 500 mph could have air over the top of the wing reach a speed of 600 mph. How fast an airplane can fly and still be considered in subsonic flight varies with the design of the wing, but as a Mach number, it will typically be just over Mach 0.8.
When an airplane is flying at transonic speed, part of the airplane is experiencing subsonic airflow and part is experiencing supersonic airflow. Over the top of the wing, probably about halfway back, the velocity of the air will reach Mach 1 and a shock wave will form. The shock wave forms 90 degrees to the airflow and is known as a normal shock wave. Stability problems can be encountered during transonic flight, because the shock wave can cause the airflow to separate from the wing. The shock wave also causes the center of lift to shift aft, causing the nose to pitch down. The speed at which the shock wave forms is known as the critical Mach number. Transonic speed is typically between Mach 0.80 and 1.20.
When an airplane is flying at supersonic speed, the entire airplane is experiencing supersonic airflow. At this speed, the shock wave which formed on top of the wing during transonic flight has moved all the way aft and has attached itself to the wing trailing edge. Supersonic speed is from Mach 1.20 to 5.0. If an airplane flies faster than Mach 5, it is said to be in hypersonic flight.