"Tim Peters" <tim.peters at gmail.com> wrote in message news:1f7befae040923012645bc07f8 at mail.gmail.com... >>>> x = [1] >>>> x.extend(-y for y in x) Very similar to this old way (2.2 and I presume before): >>> l=[1] >>> for i in l: l.append(i) ... Traceback (most recent call last): File "<stdin>", line 1, in ? KeyboardInterrupt >>> len(l) 1623613 but admittedly a bit more baroque ;-) So, are things like this a programming bug, interpreter bug, or language definition bug? or just a 'gotcha'? Terry J. Reedy
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4