Pergunta de entrevista da empresa FanDuel

Merge overlapping array of intervals