add solution for problem ten