Done exercises from chapter 7