Meta Interview Question

I was a coding question. It was quite easy to solve.