updated with come corretions for hw4 part 2