Add solutions to problems p6-p10.