Pregunta de entrevista de Robinhood

Leetcode style OA Questions, easy - medium difficulty.