opposite function to split?

2006-04-29 Thread randomtalk
hello everyone! I can't seem to find a function that combines a list of
items into a string with a seperator between the individual elements..
Is there such a method that does the opposite of sting.split? thanks
alot!

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: opposite function to split?

2006-04-29 Thread Robin Becker
[EMAIL PROTECTED] wrote:
 hello everyone! I can't seem to find a function that combines a list of
 items into a string with a seperator between the individual elements..
 Is there such a method that does the opposite of sting.split? thanks
 alot!
 
join is your answer

','.join(['a','b','c']) == 'a,b,c'

-- 
Robin Becker
-- 
http://mail.python.org/mailman/listinfo/python-list