1c Company Interview Question

Was asked to do the assignment.