Pergunta de entrevista da empresa Propelled Brands

A coding question based on DS algo.