Generation

generate functionWed, 21 Dec 2022

Change the class so that self.seniority defaults to 1 and self.intlawards = 2 class Designer(Employee): def __init__(self, name, seniority, awards): super().__init__(name, seniority) self.intlawards = awards def check_if_it_is_time_for_upgrade(self): # for each accreditation, increase the counter by 1 # for now we assume that all designers are accredited self.seniority += 1 # condition for promoting an employee from the presentation if (self.seniority) + (self.intlawards*2) % 7 == 0: self.grade_up() # publication of the results return self.publish_grade()

function that: takes two numbers as input and returns True if the first is bigger than the second and False otherwise.

Want to kickstart your project?Use the new AI Studio to create your code