define your calss class (ab)subclass of and you can use issubclass(or isinstance(functions to check relationships of two classes and instances he issubc lass(subsupboolean function returns true if the iven subclass sub is indeed subclass of the superclass sup he isinstanc (objclassboolean function returns true if obj is an instance of class class or is an instance of subclass of class overriding methodsyou can always override your parent class methods one reason for overriding parent' methods is because you may want special or different functionality in your subclass example#!/usr/bin/python class parentdefine parent class def mymethod(self)print 'calling parent methodclass child(parent)define child class def mymethod(self)print 'calling child methodc child( mymethod(instance of child child calls overridden method when the above code is executedit produces the following resultcalling child method base overloading methodsfollowing table lists some eneric functionality that you can override in your own classessn methoddesc ription sample call __init__ self [,arg constructor (with any optional arg umentssample call obj classname(args __del__self destructordeletes an object sample call dell obj __repr__self evaluatable string representation sample call repr(obj __str__self printable string representation sample call str(obj __c mp__ selfx object comparison sample call cmp(objx