Pregunta de entrevista de Weedmaps

Basic data structure question.