Answers for "python os.walk recursive"

0

python os.walk recursive

for root, dirs, files in os.walk(rootFolderPath):
    for filename in files:
        doSomethingWithFile(os.path.join(root, filename))
    for dirname in dirs:
        doSomewthingWithDir(os.path.join(root, dirname))
Posted by: Guest on September-09-2021

Python Answers by Framework

Browse Popular Code Answers by Language