solution for homework