📜  如何清除泡菜文件 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:51.475000             🧑  作者: Mango

代码示例1
#Create an empty variable
empty_list = []
#Open the pickle file in 'wb' so that you can write and dump the empty variable
openfile = open('filename', 'wb')
pickle.dump(empty_list, openfile)
openfile.close()