If you and the source of sound are moving apart, then the pitch (frequency) you hear is lower than the pitch (frequency) that's actually leaving the source.
It doesn't matter whether you or the source is the one moving, only that the distance between you is increasing.