imported chapter 25 sample code