changes from Lecture 12