[Python-ideas] Fwd: unpacking generalisations for list comprehension

אלעזר elazarg at gmail.com
Wed Oct 12 19:48:26 EDT 2016


On Thu, Oct 13, 2016 at 2:35 AM Steven D'Aprano <steve at pearwood.info> wrote:

> On Wed, Oct 12, 2016 at 04:11:55PM +0000, אלעזר wrote:
>
> > Steve, you only need to allow multiple arguments to append(), then it
> makes
> > perfect sense.
>
> I think you're missing a step. What will multiple arguments given to
> append do? There are two obvious possibilities:
>
> - collect all the arguments into a tuple, and append the tuple;
>
> - duplicate the functionality of list.extend
>
>
> neither of which appeals to me.
>

The latter, of course. Similar to max(). Not unheard of.

Elazar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20161012/b03099a0/attachment.html>


More information about the Python-ideas mailing list