Nov-18-2017, 02:38 AM
for img_scan in os.listdir('./test_folder'): if img_scan.endswith('.jpg'): print(str(img_scan))The code scans for .jpg images in the directory test_folder.
The problem is it outputs as img1.jpg img2.jpg and what I need instead is the number of images in the folder.
Also I'm not able to get it to scan for other image formats, it keeps saying single argument only.
Help please, been locked up on this issue for 3+ hours lol

