Question
####### please solve this problem with in 15 minutes.######## : Implement the MarketingOfficer and CommunicationOfficer class derived from the MarketingDepartmentEmployee class with necessary properties so
####### please solve this problem with in 15 minutes.########
: Implement the MarketingOfficer and CommunicationOfficer class derived from the MarketingDepartmentEmployee class with necessary properties so that the expected output is generated. Do not change any given code. class MarketingDepartmentEmployee: employeeInfo = {} def __init__(self, name, designation, workHour): #workHour = Per week working hour self.name = name self.designation = designation self.workHour = workHour def calculateWeeklyIncome(self): pass def __str__(self): s = f"Name: {self.name} Designation: {self.designation} Work hour per week: {self.workHour} hours" return s # Write your codes here. cm1 = MarketingOfficer("Ross","Chief Marketing Officer",45,1500) print('1.------------------------------------') cm1.calculateWeeklyIncome() print('2.------------------------------------') print(cm1) print('3.------------------------------------') cm2 = MarketingOfficer("Rachel","Chief Marketing Officer",45,2000,5) print('4.------------------------------------') cm2.calculateWeeklyIncome() print('5.------------------------------------') print(cm2) print('6.------------------------------------') print(MarketingDepartmentEmployee.employeeInfo) print('7.====================================') co1 = CommunicationOfficer("Chandler","Communication Officer",50,1000,7) print('8.------------------------------------') co1.calculateWeeklyIncome() print('9.------------------------------------') print(co1) print('10.------------------------------------') co2 = CommunicationOfficer("Monica","Chief Communication Officer",55,1200) print('11.------------------------------------') co2.calculateWeeklyIncome() print('12.------------------------------------') print(co2) print('13.------------------------------------') print(MarketingDepartmentEmployee.employeeInfo) Output: Chief Marketing Officer Ross - created. 1.------------------------------------ Weekly income of Ross has been calculated 2.------------------------------------ Name: Ross Designation: Chief Marketing Officer Work hour per week: 45 hours Per hour income: 1500 Taka Over time:0 hours Weekly income: 67500 Taka 3.------------------------------------ Chief Marketing Officer Rachel - created. 4.------------------------------------ Weekly income of Rachel has been calculated 5.------------------------------------ Name: Rachel Designation: Chief Marketing Officer Work hour per week: 45 hours Per hour income: 2000 Taka Over time:5 hours Weekly income: 100000 Taka 6.------------------------------------ {'Chief Marketing Officer': ['Ross', 'Rachel']} 7.==================================== Communication Officer Chandler - created. 8.------------------------------------ Weekly income of Chandler has been calculated 9.------------------------------------ Name: Chandler Designation: Communication Officer Work hour per week: 50 hours Per hour income: 1000 Taka Over time:7 hours Weekly income: 57000 Taka 10.------------------------------------ Chief Communication Officer Monica - created. 11.------------------------------------ Weekly income of Monica has been calculated 12.------------------------------------ Name: Monica Designation: Chief Communication Officer Work hour per week: 55 hours Per hour income: 1200 Taka Over time:0 hours Weekly income: 66000 Taka 13.------------------------------------ {'Chief Marketing Officer': ['Ross', 'Rachel'], 'Communication Officer': ['Chandler'], 'Chief Communication Officer': ['Monica']}
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started