Write the complete display output of the following code. cla…

Written by Anonymous on May 5, 2026 in Uncategorized with no comments.

Questions

Write the cоmplete displаy оutput оf the following code. clаss Employee (object):    def __init__(self, nаme, email):          self.name = name          self.email = email    def chgEmail (self, newEmail):          self.email = newEmail + '.com'          return True class Manager (Employee):      def __init__(self, name, email, salary):          super().__init__(name, email)         self.salary = salary   def chgEmail(self, newEmail):          self.email = newEmail class Worker (Employee):    def __init__(self, name, email, hourly):         super().__init__(name, email)          self.hourly = hourly           # executable code that follows the code above:e1 = Employee ('John Davis', 'jDavis@gmail.com')e2 = Employee ('James Bradley J', 'jbjones@psu.edu')w1 = Worker   ('Karina Walden', 'kwalden@state.gov', 18.50)w2 = Worker   ('Juan MacMaster', 'jmacmaster@gmail.com', '17.25')m1 = Manager  ('Warren Buffet', 'wbuffet@bhathaway.com', 92000)m2 = Manager  ('Erica Contreras', 'econtreras@gmail.com', 110000)m1.chgEmail('jbuffet@margaville.com')e1.chgEmail('JohnD@gmu.edu')print(w1.name, 'n', e1.email, 'n$', str(m1.salary), 'n', m1.email)

Comments are closed.