Question: PYTHON Define a class Person and its two child classes: Male and Female. All classes have a method getGender which can print Male for Male
PYTHON
Define a class Person and its two child classes: Male and Female. All classes have a method "getGender" which can print "Male" for Male class and "Female" for Female class.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
