Wise interview question

Implement a circuit-breaker type solution on hacker rank.