why writing list to file puts each item from list on seperate line?

homepricemaps at gmail.com homepricemaps at gmail.com
Fri Dec 30 23:22:57 EST 2005


if i use the code below to write a list to a file

list = (food, price, store)
data.append(list)
f = open(r"test.txt", 'a')
f.write ( os.linesep.join( list ) )


it outputs to a file like this

apple
.49
star market

and i want it to do

apple, .49. star market

any ideas




More information about the Python-list mailing list