Python : How to get list of files in directory and sub directories

In this article we will discuss different methods to generate a list of all files in directory tree. Creating a list of files in directory and sub directories using os.listdir() Python’s os module provides a function to get the list of files or folder in a directory i.e. os.listdir(path='.') It returns a list of all … Continue reading Python : How to get list of files in directory and sub directories