python简单读取文件案例二

在原来文本的基础上添加新的信息 text = "新添加的内容" my_file = open('my file.txt','a') my_file.write(text) my_file.close() 结果:
相关文章
相关标签/搜索