solution for hw 5 1747127