Pergunta de entrevista da empresa Better

Codility 3 problems assessment. LeetCode Easy-Medium