Sopra Steria interview question

Write a program for functional and class based components