News for hackers. Stuff that matters.
Re:Python idioms by imurray on Sunday June 12, 2011 @02:14PM (#2647015)
Always worth checking. Although the relative merits change when doing many joins to build up a single long string.

This recommendation is to go with .join() by default:

In performance sensitive parts of the library, the ''.join() form should be used instead. This will ensure that concatenation occurs in linear time across various implementations. — http://www.python.org/dev/peps/pep-0008/

despite the fact it might not be better in CPython.

There are no comments on this comment yet.