Я правильно понимаю os.walk?
Цикл для root, dir, file inos.walk(startdir)
работает через эти шаги?
for root in os.walk(startdir)
for dir in root
for files in dir
get root of start dir : C:\dir1\dir2\startdir
get folders in C:\dir1\dir2\startdir and return list of folders "dirlist"
get files in first dirlist item and return list of files "filelist" as the first item of a list of filelists.
move to second item in dirlist and return list of files in this folder "filelist2" as the second item of a list of filelists. etc.
move to next root in foldertree and start from 2. etc.
Правильно? Или он сначала получает все корни, потом все dirs, а все файлы третьи?