Updates the code samples in the book