如下所示: //用普通文本文件方式打开和操作 with open("'file.csv'") as cf: lines=cf.readlines() ...... //用普通文本方式打开,用csv模块操作 import csv with open("file.csv") as cf: lines=csv.reader(cf) for line in lines: print(line) ...... import csv headers=['id','username','password','age','country'] r