search for file in a whole system

Solutions on MaxInterview for search for file in a whole system by the best coders in the world

showing results for - "search for file in a whole system"
Ed
22 Oct 2020
1import os
2
3def search(drive,name):
4    for dirpath, dirs, files in os.walk(drive):
5        if name in files:
6            return (os.path.join(dirpath, name))
7