add program to count files without using boost lib