I have a dictionary which contains a list of 4 items per key.
I'm trying to write each individual list item to a Var column in a CSV file, but I haven't been having much luck.
try:
f = open('numbers2.csv', 'wt')
writer = csv.writer(f, lineterminator = '\n')
writer.writerow(('Var1', "Var2", 'Var3', "Var4",))
for x in exchangeDict2.iteritems():
writer.writerow(x)
This code will print the key in one column, and the list in the other.