completed the assignment 2