Domanda di colloquio di X

Build some UI with React. Solve this algorithm question.