Solve SICP exercise 2.22
Solve SICP exercise 2.23