def act(self) act(selfprint('eggs'name superclass explicitlypass self ( act(spam eggs this form works the same in and xfollows python' normal method call mapping modelapplies to all inheritance tree formsand does not lead to confusing behavior when operator overloading is used to see why these distinctions matterlet' see how super compares basic super usage and its tradeoffs in this sectionwe'll both introduce super in basicsingle-inheritance modeand look at its perceived downsides in this role as we'll findin this context super does work as advertisedbut is not much different from traditional callsrelies on unusual semanticsand is cumbersome to deploy in more criticallyas soon as your classes grow to use multiple inheritancethis super usage mode can both mask problems in your code and route calls in ways you may not expect odd semanticsa magic proxy in python the super built-in actually has two intended roles the more esoteric of these--cooperative multiple inheritance dispatch protocols in diamond multiple-inheritance trees (yesa mouthful!)--relies on the mrowas borrowed from the dylan languageand will be covered later in this section the role we're interested in here is more commonly usedand more frequently requested by people with java backgrounds--to allow superclasses to be named generically in inheritance trees this is intended to promote simpler code maintenanceand to avoid having to type long superclass reference paths in calls in python xthis call seems at least at first glance to achieve this purpose wellclass cdef act(self)print('spam'class ( )def act(self)super(act(print('eggs'in python (onlysee super form aheadreference superclass genericallyomit self ( act(spam eggs the super built-in functionfor better or worse