modified assignment 2