add solution to homework 6