Give a suitable example using Python code to illustrate single level inheritance considering COUNTRY to be BASE class and STATE to be derived class.

4 views

1 Answers

Class COUNTRY: statejist = [ ]

def_init_(self, name):

self.name = name class state (COUNTRY):

def_init_(self, name, capital): super ( )._init_(name)

self.capital = capital

4 views