Cookbook up to exercise 3