The crack from a whip is actually a sonic boom, caused by the end of the whip breaking the sound barrier.

This is possible because a whip tapers from handle to tip.

When the whip is used, the energy imparted to the handle sends a wave down the length of the whip. As this wave travels down the tapering whip it acts on a progressively smaller cross-section and a progressively smaller mass.

The energy of this wave is a function of mass and velocity and since the energy of the wave must be conserved, it follows that if mass is decreasing as the wave travels down the whip, then velocity must increase.

Therefore, the wave travels faster and faster, until by the time it reaches the tip it has attained the speed of sound.

When the wave reaches the tip of the whip it must be dissipated.

Some goes to the air and some into a reflected wave that travels back up the whip. At the point that the initial wave reaches the tip and is about to embark on its return it undergoes a brief but enormous acceleration.

The result is that it moves supersonically.