[Tutor] Converting string or list to sum

Kalle Svensson kalle at lysator.liu.se
Fri Jan 30 17:30:15 EST 2004


[Isr Gish]
> Kalle Svensson Wrote:
>    >I'd write
>    >
>    >  d = ''.join(map(str, a))
>    >
>    >since that's probably much faster for large lists.
>  
> I think that should be:
> import __builtin__
> d = ''.join(map(__builtin__.str, a))

Why?

(There's no need to CC me on replies, I read the list.)

Peace,
  Kalle
-- 
Kalle Svensson, http://www.juckapan.org/~kalle/
Student, root and saint in the Church of Emacs.



More information about the Tutor mailing list