Added solution to assignment 1 problem 3.

Also created a smaller output.txt file for faster processing.