📜  在整个系统中搜索文件 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:13.679000             🧑  作者: Mango

代码示例1
import os

def search(drive,name):
    for dirpath, dirs, files in os.walk(drive):
        if name in files:
            return (os.path.join(dirpath, name))