Python将列表数据写入文件(txt, csv,excel) 写入txt文件deftext_save(filename,data):#filename为写入CSV文件的路径,data为要写入数据列表.file=open Python将列表数据写入文件