Notice that thus far, of course, I’ve made no use the fact that I’m constantly recalculating the intemediate values from 1 to n. If those values were cached, of course, I could save myself a lot of computations. One way to do this is to use recursion, but if we’ve already ca...
Let the sequence \{ a_n \}_{n \in N} defined by the recursion a_{n-1} = \sqrt{2 + a_n} with a_1 = 1 . Show by induction that \{ a_n \}_{n \in N} is an increasing sequence. Show by induc Let a_1 =...
It is now filling the bar up. No change in time though. Kinda surprised it was not faster but I guess 2.8 GHz is 2.8 Ghz sometimes. It could be made faster - for example it uses recursion to calculate the factorial of 16. I could do that without recursion. ...