http://www.Sina.com/http://www.Sina.com /
创建名为mytxtfile的txt文件,然后单击msgdeftext_create(name, msg ) :写入desktop _ path=' c : (_ SERS ) _administration )文件' #新创建的txt文件的存储路径full _ path=desktooth 也可以为. doc创建word文档file=open(full_path,' w ' ) file.writt # file.close (text _ create ) ' mytxtfile ) #调用函数创建名为mytxtfile的. txt文件,并将其写入Hello world! 结果是这样的: