lecture 9; updates to lecture 7