对于文件名的匹配,你可能会考虑使用 glob 或 fnmatch 模块。比如:. import glob pyfiles = glob.glob('somedir/*.py') from fnmatch import fnmatch pyfiles = [name ...
確定! 回上一頁