simple scripts from chapter 2