Wise Interview Question

Implement a circuit-breaker type solution on hacker rank.