final version assignment 2