python count file number in a folder code example
Example 1: python count files directory
import os
len(os.listdir(directory))
Example 2: count a number of file in a folder python
import os
len([item for item in os.listdir(folderPath)])
import os
len(os.listdir(directory))
import os
len([item for item in os.listdir(folderPath)])