Added the ability for the program to count the number of files.