Updating chapter 4 example