Pregunta de entrevista de Meta

Algorithm questions from leetcode medium level