Question: Using python T-Mobile 10:54 AM a mymasonportal.gmu.edu In-lab assignment # 3 Topics: class, object, instantiation, basic inheritance Due: in lab Problem Statement: The purpose of
T-Mobile 10:54 AM a mymasonportal.gmu.edu In-lab assignment # 3 Topics: class, object, instantiation, basic inheritance Due: in lab Problem Statement: The purpose of this lab assignment is to gain experience in pythons inheritance feature. 1. You are given a base class called Faculty. You are going to implement one child class called Principal 2. The parent class has three methods: ait (self, name]: this method takes one parameter, name of the faculty b. average(self, ratingi, rating2, rating3]:This method takes three integer values ranging from 0-30 and calculates average rounded to two decimall points C.-Str_1self): this method prints the information. 3. Your Task: You need to define two methods in Principal class: init and ratings Please see name of the principal You can choose to use supent) to call the super class method. people skils, speaking skills. They range from 0-10. Example: below: a. init Ise, namel: which will initialize the super classntmethod with b. rating(velf): Asks user for input in three areas of rating: managements skils Rating for the Principal: Management skills:9 People skills:& Speaking skills: 6 4. You need to define a maing function and considering the definition of the parent dlass main() function: A sample main steps can be as follows L Take name of Principal and creating a principal object with that name i. Invoke ratings0 to get user input i.Invekestr 0 to print the details i. Fyi, Subclass will have access to all the methods and attributes of the parent class Sample inout/output Enter name of faculty: Obama Rating for the Principal: Management skills: S People skills: 10 Speaking skith:9 Details of the faulty: Obama with a rating of 9.33 L All submission will be via BlackBoard during the lab time
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
