Added solution to problem six.