""alternative implementation of person classeswith databehaviorand operator overloading (not used for objects stored persistently""class person"" general persondata+logic ""def __init__(selfnameagepay= job=none)self name name self age age self pay pay self job job def lastname(self)return self name split()[- def giveraise(selfpercent)self pay *( percentdef __str__(self)return (% % % >(self __class__ __name__self nameself jobself pay)class manager(person)"" person with custom raise inherits general lastnamestr ""def __init__(selfnameagepay)person __init__(selfnameagepay'manager'def giveraise(selfpercentbonus= )person giveraise(selfpercent bonusif __name__ ='__main__'bob person('bob smith' sue person('sue jones' 'hardware'tom manager(name='tom doe'age= pay= print(suesue paysue lastname()for obj in (bobsuetom)obj giveraise run this obj' giveraise print(objrun common __str__ method notice the polymorphism in this module' self-test loopall three objects share the constructorlast-nameand printing methodsbut the raise method called is dependent upon the class from which an instance is created when runexample - prints the following to standard output--the manager' job is filled in at constructionwe get the new custom display format for our objectsand the new version of the manager' raise method works as beforesue joneshardware jones bob smithnone sue joneshardware tom doemanager step stepping up to oop