Pregunta de entrevista de Decagon

leetcode medium level design question