[Python-ideas] Add list.join() please

Steven D'Aprano steve at pearwood.info
Tue Jan 29 18:04:57 EST 2019


On Tue, Jan 29, 2019 at 10:51:26PM +0100, Jamesie Pic wrote:

> What do you think of list.stringify(delim) ?

What's so special about lists? What do you think of:

    tuple.stringify
    deque.stringify
    iterator.stringify
    dict.keys.stringify

etc. And what's so special about strings that lists have to support a 
stringify method and not every other type?

    list.floatify
    list.intify
    list.tuplify
    list.setify
    list.iteratorify

Programming languages should be more about composable, re-usable general 
purpose components more than special cases.


-- 
Steve


More information about the Python-ideas mailing list