String help

Padraig Brady Padraig at Linux.ie
Mon Oct 7 15:31:03 CEST 2002


CheapSkate wrote:
> Hi, I got
> a string = "aaa,bbb,ccc"
> I want to seperate the string into 3 string "aaa" "bbb" "ccc"
> How do I do it?
> 
> I know I need to use split.
> but I don't know how, even after reading it.
> 
> Can someone give me an e.g!

"aaa,bbb,ccc".split(',')

Pádraig.




More information about the Python-list mailing list