problem_41 and clean up