def append_list_as_row(file_name, list_of_elem):
# Open file in append mode
with open(file_name, 'a+', newline='') as write_obj:
# Create a writer object from csv module
csv_writer = writer(write_obj, quoting=csv.QUOTE_ALL)
# Add contents of list as last row in the csv file
csv_writer.writerow(list_of_elem)
append_list_as_row(userlogin,log_ins)
谢谢你,维尼什。我能够找到一个csv函数来解决我的问题。我离开了堆栈,因为至少在我目前的python技能中,在这种情况下它是不可行的
您需要更改三行代码才能使其正常工作。 单独替换此部分
相关问题 更多 >
编程相关推荐