homework lecture 3 problem 2 ui