参考代码:
data=['one','two','three'] with open('data.txt','w') as fw: fw.writelines([item+'\n' for item in data])
浙公网安备 33010602006230号
浙ICP备14015892号