Writing Python lists to columns in csv

Change them to rows:

rows = zip(list1, list2, list3, list4, list5)

Then just:

import csv

with open(newfilePath, "w") as f:
    writer = csv.writer(f)
    for row in rows:
        writer.writerow(row)

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)