[Tutor] convert array into string

alan.gauld@bt.com alan.gauld@bt.com
Fri, 30 Aug 2002 17:41:49 +0100


> How would I convert something like:
> abc = ["abcdef"]
> into
> abc = "abcdef"

abc = abc[0]

I think the str() function works on lists too.

> What I'm actually trying to do is convert a file.readlines() into a
> single string and then .split(" ").  Is this possible?  

Use read() instead - it returns onre enormous string...

Alan G.