added exercises 4.29 and 4.30