python csv在哪个模块
发布网友
发布时间:2022-07-23 02:13
我来回答
共1个回答
热心网友
时间:2023-11-21 00:37
标准库就自带csv模块
>>> import csv
>>> spamReader = csv.reader(open('eggs.csv', 'rb'), delimiter=' ', quotechar='|')
>>> for row in spamReader:
... print ', '.join(row)
Spam, Spam, Spam, Spam, Spam, Baked Beans
Spam, Lovely Spam, Wonderful Spam