import os
os.path.isfile('test.txt') # 如果不存在就返回False
os.path.exists(directory) # 如果目录不存在就返回False
os.makedirs(targetDir)
os.path.join(targetDir, file)os.remove(targetFile)
import os
os.path.isfile('test.txt') # 如果不存在就返回False
os.path.exists(directory) # 如果目录不存在就返回False
os.makedirs(targetDir)
os.path.join(targetDir, file)os.remove(targetFile)
上一篇:awk输出单引号,双引号
下一篇:python字符串函数
文件、目录权限r:可读 w:可写 x:可执行 4 2 1(第一
举报文章
请选择举报类型
补充说明
0/200
上传截图
格式支持JPEG/PNG/JPG,图片不超过1.9M