On Tue, Sep 15, 2009 at 10:31 PM, Ulrich Eckhardt
<eckha...@satorlaser.com>wrote:

> "'abc'.split('')" gives me a "ValueError: empty separator".
> However, "''.join(['a', 'b', 'c'])" gives me "'abc'".
>
> Why this asymmetry? I was under the impression that the two would be
> complementary.
>

I'm not sure about asymmetry, but how would you implement a split method
with an empty delimiter to begin with? It doesn't make much sense anyway.

If you feel strongly to make it do what you want it to do, it might be a
good idea to submit it to Python-ideas mailing list, or such.

Otherwise, it doesn't hurt to iterate over the string and make use of them,
right? ;)

Cheers,
Xav
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to