Implement throttle, for example allowing an input function to run at most once every 50 milliseconds.

reported at Google

say it first

Answer it out loud, in your own words. Then compare.

Interviewers listen for how you get there, not only where you land. The answer opens once you have tried.