会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
stone
工作:python,数据,模型,统计,web后端;
爱好:英超,历史,讨论,聊天,侃大山;
博客园
首页
新随笔
联系
订阅
管理
2024年8月28日
python获取目录下的所有文件、子目录
摘要: 1. 相对路径 import os source_path=r'你的目录' for root,dirs,files in os.walk(source_path): print('当前目录为:',root) print('当前目录下的子目录为:') for dirname in dirs: prin
阅读全文
posted @ 2024-08-28 16:06 stone9693
阅读(2239)
评论(0)
推荐(0)
公告
GitHub账户:https://github.com/stone9693