Pergunta de entrevista da empresa Epic

Leetcode type Coding challenge of medium - hard difficulty.