# EmployeeHierarchy Example # Illustrate how inheritance works: # Person < Employee < Executive # An Executive is an Employee with a bonus. from person import Person class Employee(Person): def __init__(self, the_name, the_gender, the_age, \ the_id, the_salary): super( ).__init__(the_name, the_gender, the_age) self.id = the_id self.salary = the_salary def __str__(self): return super( ).__str__( ) + f" {self.id} {self.salary}" def compensation(self): return self.salary