Extending classes __init__behavior for newbies

rantingrick rantingrick at gmail.com
Sun Feb 13 23:29:14 CET 2011

On Feb 13, 4:21 pm, MRAB <pyt... at mrabarnett.plus.com> wrote:

> I would've done it this way:
> class FasterShip(Ship):
>      def __init__(self, speed=0, **kwargs):
>          Ship.__init__(self, **kwargs)
>          self.speed = speed

Well it seem MRAB and i actually agree on *one* thing. Well, when they
said... "great minds think alike" ...they never mentioned *anything*
about frequency.  ;-)

More information about the Python-list mailing list