Pregunta de entrevista de Amazon

Coding was about graphs(leet code hard), and logical design