# SICP Solutions

### Section - Formulating Abstractions with Higher-Order Procedures

#### Exercise 1.45

I tried to fing the value for number of damping but unable to do so. Thus I have written the procedure that takes number of dampings also as an argument.

Here is the complete program including all the required other procedures:

I verfied that 4th root requires twice damping as mentioned in exercise. Then I checked till 12th root and twice damping works fine.

But at 13th root I tried with $3, 4$ but program was not returning. There may be following cases:

• Either program is actually taking too much time for converging.
• Or the damping is not enough and program is going into infinite loop.

One way to figure out if it is going to infinite loop, is to modify the procedure fixed-point to store all the in between states. And as soon as a state is repeated we can report that and exit the program.

I have not implemented the said way because of shortage of time.

Here is the sample that I have tried: