finish machine-learning assignment 3