IBM Interview Question

to build a react component