Question d’entretien chez Apple

Oop question in python and make the function.