Added command-line options and refactored code

Now, we can accept command-line options that specify the configuration
file, the date on which we compute the times, and the output type. I
also did some code refactoring.