how to create a list from csv python

56

how to create a list from csv python -

import csv

with open('file.csv', newline='') as f:
    reader = csv.reader(f)
    data = list(reader)

print(data)

Comments

Submit
0 Comments