so, the problem is you incorrect expectation that
check
https://stackoverflow.com/a/18282401/4046632
Also, because paths has both dirs and files, it is normal to expect that when you sort it some [hidden] files/folders will come on the top, because of the . i.e. even if
os.walk()
returns result in alphabetic/sorted order, which however is not the casecheck
https://stackoverflow.com/a/18282401/4046632
Also, because paths has both dirs and files, it is normal to expect that when you sort it some [hidden] files/folders will come on the top, because of the . i.e. even if
os.walk()
returns folders in alphabetic order, when you sort mix of files and folders the result may differ.
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs