Solutions to chapter 2