added use of argparse
added option of explicitly specifying a list of files on the command line
Broke up program into smaller chucks. Added ability to specify other input file.