Answered step by step
Verified Expert Solution
Question
1 Approved Answer
class Duration: def init (self, hours, minutes): self.hours = hours self.minutes = minates def add (self, other): If not isinstance (other, Duration): return 'oops total
class Duration: def init (self, hours, minutes): self.hours = hours self.minutes = minates def add (self, other): If not isinstance (other, Duration): return 'oops total hours - self.hours + other.hours total minutes \# self.minutes - other.minutes if total minutes x=60 : totafinouns +1 totalminutes 60 return puration (totel hours, total minutes) one way time = Duratyon (5, 48) round trip time one watime + one way time print cone way time + 38 ) print (zound trip time.houflo found thip time.minutes)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access with AI-Powered 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