Mark Tolonen wrote:
> It's a good idea to cut-and-paste actual code and actual output. Your
> above code doesn't work.
I'd just like to clarify, in case someone misunderstood, it isn't a
really good idea to simply cut-and-paste actual code and actual output
for 2 reasons:
1) cut-and-paste means
"Kent Johnson" wrote in message
news:1c2a2c590906230415q351c7c74kebc591907ce0e...@mail.gmail.com...
On Tue, Jun 23, 2009 at 1:08 AM, Mark Tolonen
wrote:
import csv
dyc = {
'a50' : ['textfield', 50, 40],
'k77' : ['othertext', 60, 10]
}
myfile = open('csv-test.csv', 'w')
mywriter = csv.writ
On Tue, Jun 23, 2009 at 1:08 AM, Mark Tolonen wrote:
> import csv
>
> dyc = {
> 'a50' : ['textfield', 50, 40],
> 'k77' : ['othertext', 60, 10]
> }
>
> myfile = open('csv-test.csv', 'w')
> mywriter = csv.writer(myfile, dialect='excel')
>
> for k,[a,b,c] in dyc.items():
> mywriter.writerow([k,a,b,
"Eduardo Vieira" wrote in message
news:9356b9f30906221404o7a7c5e5dt3d59e7b6d40ac...@mail.gmail.com...
Hello, I have a dictionary similar to this:
dyc = {
'a50' : ['textfield', 50, 40],
'k77' : ['othertext', 60, 10]
}
I was trying to write a csv with the csv module, by doing this:
import csv
m
Hello, I have a dictionary similar to this:
dyc = {
'a50' : ['textfield', 50, 40],
'k77' : ['othertext', 60, 10]
}
I was trying to write a csv with the csv module, by doing this:
import csv
myfile = open('c:/myscripts/csv-test.csv', 'wb')
mywriter = csv.writer(myfile, dialect='excel')
for item in