DXC Technology interview question

Implement the debounce function from scratch