Laurent Claessens writes: > Le 30/05/2011 11:02, Terry Reedy a écrit : > > On 5/30/2011 3:38 AM, Laurent wrote: > > > >> Cool. I was thinking that "5" was the name, but > >> >>> 5.__add__(6) > >> File "<stdin>", line 1 > >> 5.__add__(6) > > > > > > Try 5 .__add__(6) > > What is the rationale behind the fact to add a space between "5" and > ".__add__" ? > Why does it work ?
Oh joy. >>> [5][0].__add__([6][-1]) 11 The parser just needs the help to detect the intended token boundary instead of another, unintened one. As the others already say. -- http://mail.python.org/mailman/listinfo/python-list