Added solution to homework #2.