#---------- Python "signature-based" polymorphism----------# def Print(x): from types import * if type(x) is FloatType: print "float", x elif type(x) is IntType: print "int", x elif type(x) is LongType: print "long", x