You can clap your hands to a calibrated delay from the previous beat that you heard (predicting the next beat before you hear it). This is analogous to the principle of a phase-locked loop, which gradually adjusts an internal oscillator until it matches an external frequency. That internal oscillator can emit a beat just before the real one, offset just enough to cancel all the delays in the processing path.
This only works if the beat you're hearing is sufficiently stable.