Question: class Residence: def _ _ init _ _ ( self , addr ) : self.address = addr def get _ residence ( self ) :

class Residence:
def __init__(self, addr):
self.address = addr
def get_residence (self):
print (f'Address: {self.address}')
class Identity:
def __init__(self, name, age):
self.name = name
self.age = age
def get_Identity (self):
print (f'Name: {self.name}, Age: {self.age}')
class DrivingLicense (Identity, Residence):
def __init__(self, Id_num, name, age, addr):
Identity.__init__(self,name, age)
Residence.__init__(self,addr)
self.License_Id = Id_num
def get_details (self):
print (f'License No.{self.License_Id}, Name: {self.name}, Age: {self.age}, Address: {self.address}')
license = DrivingLicense(180892,'Bob',21,'California')
license.get_details()
license.get_Identity()

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!