Answered step by step
Verified Expert Solution
Question
1 Approved Answer
birthday 1 and birthday 2 are instances of the Birthday class. Attributes month, day, and year of both birthday 1 and birthday 2 are read
birthday and birthday are instances of the Birthday class. Attributes month, day, and year of both birthday and birthday are read from input. In the Birthday class, define instance method printdayofbirth with self and one string as parameters to output the following in one line:
The string parameter
The value of attribute month
The value of attribute day
The value of attribute yearclass Birthday:
def initself:
self.month
self.day
self.year birthday Birthday
birthdaymonth intinput
birthdayday intinput
birthdayyear intinput
birthday Birthday
birthdaymonth intinput
birthdayday intinput
birthdayyear intinput
birthdayprintdayofbirthFirst date of birth
birthdayprintdayofbirthSecond date of birth
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